More radical ideas about gc and reference counting

Timon Gehr via Digitalmars-d digitalmars-d at puremagic.com
Tue May 13 14:16:54 PDT 2014


On 05/13/2014 09:07 PM, Jacob Carlborg wrote:
> On 2014-05-13 15:56, Dicebot wrote:
>
>> Judging by http://static.rust-lang.org/doc/0.6/tutorial-macros.html
>> those are not full-blown AST macros like ones you have been proposing,
>> more like hygienic version of C macros.
>
> Hmm, I haven't looked at Rust macros that much.
>

Again, the following is an example of Rust macros in action. A bf 
program is compiled to Rust code at compile time.

https://github.com/huonw/brainfuck_macro/blob/master/lib.rs

Compile-time computations create an AST which is then spliced. Seems 
full-blown enough to me and not at all like C macros.


More information about the Digitalmars-d mailing list