←back to thread

196 points svlasov | 2 comments | | HN request time: 0s | source
Show context
pjmlp ◴[] No.40851159[source]
Note that there are links pointing to examples on Compiler Explorer, using the EDG and clang preview implementations.
replies(1): >>40851532 #
1. a_e_k ◴[] No.40851532[source]
Yes, that's a clever way of demonstrating viability (and with more than one compiler implementation).

I do like the examples that I see there.

This seems like the kind of language feature that I might not make much use of directly in general application code, but would wrap up in utility functions or use via lower-level libraries that the application code builds on. E.g., they showed command-line parsing, but I could also see this for benchmarking and testing frameworks to automatically find the workloads and tests in a non-hacky way.

I also wonder about how this feature interacts with translation units or modules and linkage, though. I'm reminded of the static initialization order fiasco; this seems like it might open up issues that make that look tame by comparison. (Not a complaint; I'm actually looking forward to this.)

replies(1): >>40854257 #
2. pjmlp ◴[] No.40854257[source]
I am a big defender that the only way to fix many of the mistakes that ended up in the standard is to adopt the same policy as other languages, papers without preview implementations shouldn't be accepted.

There are still a few gotchas being ironed out, there was a talk at ACCU about many corner cases.