On Sat, 26 Jan 2013, Sven Barth wrote:
grouping of values.
That's why I proposed them as extensions. I'm myself not very sure in
allowing them or not, but I added them for Alexander's sake ;)
I would also not allow operators other than := <> and =, because in
expressions,
when encountering a (, it is not clear what is meant.
Here are two possiblities:
* allow operator overloads only for named tuples, which would mean that only
"t3 := t1 + t2" would be supported
* allow operator overloads also for anonymous tuples, which would mean that
(like I wrote in open issues) "(d1, d2, d3, d4) := (d1, d2, d3, d4) + (1.0,
2.0, 3.0, 4.0)" would be supported
I meant that when doing
a + (1,2,3)
When parsing the expression, the meaning of the ( 'tuple constructor' in this case,
becomes only clear when processing the first comma (,)
I do not think this is something we should allow.
So *if* you want to allow operators, only on named tuples.
Michael.
_______________________________________________
fpc-devel maillist - fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel