lua-users home
lua-l archive

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


2010/7/20 Luiz Henrique de Figueiredo <lhf@tecgraf.puc-rio.br>:
>> sh. gcc { o = file } (file..'.c") .I. grep 'error' .I. sort .out
>
> The closest thing to a pipe symbol is the division operator:
>
>  sh. gcc { o = file } (file..'.c") / grep 'error' / sort .out
>
> It has the right (ie, left!) associativity.

But is graphical matching a good goal ? IMHO the closest semantic
operation to piping in Lua is concatenation, hence my use of .. as a
piping operator in an earlier example. But afaict it has the wrong
(ie, right!) associativity :-)