Re: The New CTFE Engine on the Blog
On Wednesday, 12 April 2017 at 05:51:20 UTC, Ali Çehreli wrote: On 04/10/2017 06:07 AM, Mike Parker wrote: Stefan has been diligently keeping us all updated on NewCTFE here in the forums. Now, he's gone to the blog to say something to tell the world about it. The blog: https://dlang.org/blog/2017/04/10/the-new-ctfe-engine/ Reddit: https://www.reddit.com/r/programming/comments/64jfes/an_introduction_to_ds_new_engine_for_compiletime/ The first code sample is private immutable ubyte[128] uri_flags = // indexed by character ({ // ... })(); and the text says "The ({ starts a function-literal, the }) closes it.". Why the extra parentheses? Just the curly brackets works, no? private immutable ubyte[128] uri_flags = // indexed by character { // ... }(); Ali Yes it would work. But I like to distinguish function-literals from blocks :)
Re: The New CTFE Engine on the Blog
On 04/10/2017 06:07 AM, Mike Parker wrote: Stefan has been diligently keeping us all updated on NewCTFE here in the forums. Now, he's gone to the blog to say something to tell the world about it. The blog: https://dlang.org/blog/2017/04/10/the-new-ctfe-engine/ Reddit: https://www.reddit.com/r/programming/comments/64jfes/an_introduction_to_ds_new_engine_for_compiletime/ The first code sample is private immutable ubyte[128] uri_flags = // indexed by character ({ // ... })(); and the text says "The ({ starts a function-literal, the }) closes it.". Why the extra parentheses? Just the curly brackets works, no? private immutable ubyte[128] uri_flags = // indexed by character { // ... }(); Ali
The New CTFE Engine on the Blog
Stefan has been diligently keeping us all updated on NewCTFE here in the forums. Now, he's gone to the blog to say something to tell the world about it. The blog: https://dlang.org/blog/2017/04/10/the-new-ctfe-engine/ Reddit: https://www.reddit.com/r/programming/comments/64jfes/an_introduction_to_ds_new_engine_for_compiletime/