Community
Participate
Working Groups
Build Identifier: I20110613-1736 Trying this in PureXBase: val a = 5 val (int, int)=>int sum = [a, b | a + b] results in the following error: "Duplicate variable name 'a'". Is it a feature? Isn't the parameter supposed to shadow the outer 'val'? Thanks. Reproducible: Always Steps to Reproduce: PureXBase: val a = 5 val (int, int)=>int sum = [a, b | a + b]
Xbase does not support variable shadowing for now. It is explicitly validated that you use unique variable names.
See last comment. We don't have concrete plans to change the semantics.