[m-rev.] for review: add <<u and >>u as operators
Julien Fischer
jfischer at opturion.com
Mon Dec 5 14:51:58 AEDT 2022
On Sun, 4 Dec 2022, Zoltan Somogyi wrote:
> Recognize <<u and >>u as operators.
>
> library/ops.m:
> Add these to the list of operators, at the same priority as << and >>.
>
> library/mercury_term_lexer.m:
> <<u and >>u are the first operator that combine graphic characters with
s/operator/operators/
> alphanumeric characters. This requires extending the lexer, because
> if the lexer, when given e.g. the string "<<u", returns "<<" and "u"
> as separate tokens, then the presence of <<u in the ops table
> would not matter.
>
> Implement this special case in all three different variants of the lexer.
>
> doc/reference_manual.texi:
> Document the new operators, and their special-case nature.
That's fine otherwise.
Julien.
More information about the reviews
mailing list