Skip to content

Instantly share code, notes, and snippets.

@jacob-carlborg
jacob-carlborg / gsoc-d-ideas.md
Last active February 28, 2019 11:18
GSoC D Ideas

GSoC Ideas

DMD as a Library

The basic work has already been done but a lot more could be done to make DMD more suitable as a library.

  • Mostly removing global state. Also make the diagnostic handling configurable. Now all diagnostic messages that occurs after parsing are always outputted to stderr. Making more things pure is a good way to
@jacob-carlborg
jacob-carlborg / gist:b3c91a94f306564158b2a6ac58a57d50
Last active September 13, 2018 07:19
Go 2 draft D corrections

The examples for D while they will most likley compile, it's not really how one would write D templates today. I also provide usage examples showing that everything compiles as expected.

Set example:

// no need to use the template keyword
struct Set(T) if(is(typeof(T.init == T.init))) // Verify T has equlity
{
    void add(T o) {}
2018/08/23 08:58:17 [INFO] Terraform version: 0.11.8 7a5c1d221ac209bbac66947c369815cd9ca70ed5
2018/08/23 08:58:17 [INFO] Go runtime version: go1.10.1
2018/08/23 08:58:17 [INFO] CLI args: []string{"/usr/local/bin/terraform", "apply", "-auto-approve"}
2018/08/23 08:58:17 [DEBUG] Attempting to open CLI config file: /Users/jacobc/.terraformrc
2018/08/23 08:58:17 [DEBUG] File doesn't exist, but doesn't need to. Ignoring.
2018/08/23 08:58:17 [INFO] CLI command args: []string{"apply", "-auto-approve"}
2018/08/23 08:58:17 [INFO] command: empty terraform config, returning nil
2018/08/23 08:58:17 [DEBUG] command: no data state file found for backend config
2018/08/23 08:58:17 [DEBUG] New state was assigned lineage "7f422872-75f2-da19-2c42-50e455b8d655"
2018/08/23 08:58:17 [INFO] command: backend initialized: <nil>