[erlang-questions] about syntax tools

Andrew Kondratovich andrew.kondratovich@REDACTED
Fri Aug 5 11:32:33 CEST 2011


How can i add some syntax expressions in language without editing
source grammatics ?

For example, i want to add something like list generator:
[1..6] % generates [1,2,3,4,5,6]

With macros, i can do something like:

-define(Seq(A, B), lists:seq(A, lists:max([A, B]))).

and then

?Seq(A, B).

in code.

Can i add my own syntax rules by syntax tools or something like that ?

More information about the erlang-questions mailing list