HaxeFoundation / HaxeManual

The official Haxe manual
https://haxe.org/manual/
Creative Commons Attribution 4.0 International
218 stars 154 forks source link

Add examples to macro reification #540

Closed Speedphoenix closed 4 months ago

Speedphoenix commented 4 months ago

Also move $v{} higher in the list

The lack of examples here was one of my main deterrents from using macros in the past

Simn commented 4 months ago

These examples are somewhat convoluted, mixing several concepts and making it difficult to map the input to the output. IMO this content would be better suited for a page on https://code.haxe.org, which could then be linked from the manual.

The $v reordering seems arbitrary, but one thing it makes me realize is that we should update the "only guaranteed to work for" part, especially if we add examples that go beyond that.

tobil4sk commented 4 months ago

The $v reordering seems arbitrary

Also, it looks like this list is alphabetical?

Simn commented 4 months ago

The $v reordering seems arbitrary

Also, it looks like this list is alphabetical?

Uhm right, I totally knew that!