[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Extensible syntax




> Of course there's a ton of preprocessors that allow one to extend a
> languages grammar, but this is something of a heavyweight approach, and
> may suffer from lack of modularity?? I'm after something lightweight and
> built-in, similar to the way Lisp lets me just fire off a defmacro as
> easily as a defun.

Prolog supports the definition of custom prefix, infix, and postfix
operators, using precedence for disambiguation.

http://www.sics.se/sicstus/docs/latest/html/sicstus/Operators.html


Kimberley Burchett
http://www.kimbly.com/