Home

BUG(V5.22.02, C# Program): Cannot execute text selection


//LINQPad_V5_22_02_Bug_CannotExecuteTextSelection.linq
void Main() {
42.Dump();
}

/** text selection 0 -> Cannot execute ... if in "C# Program"
from x in Enumerable.Range(start:char.MinValue,count:char.MaxValue-char.MinValue+1)
let c = (char)x
let isDigit = char.IsDigit(c)
where isDigit
select new{ x, c, isDigit }
**/
/** text selection 1 -> OK
from x in Enumerable.Range(start:char.MinValue,count:char.MaxValue-char.MinValue+1)
let c = (char)x
let isDigit = char.IsDigit(c)
where isDigit
select ( x, c, isDigit ) // <= instead of select new ...
**/
/** text selection 2 -> Cannot execute ...
from x in Enumerable.Range(start:char.MinValue,count:char.MaxValue-char.MinValue+1)
let c = (char)x
let isDigit = char.IsDigit(c)
where isDigit
select ( x, c, isDigit ) // <= instead of select new{ x, c, isDigit }
**/

/**
Error from text selection 0 and 2.
Occurs for "C# Program" only, not for "C# Statement(s)" or "C# Expression"
**//**
Cannot execute text selection: CS1003 Syntax error, ',' expected

CS1002 ; expected

CS1519 Invalid token '(' in class, struct, or interface member declaration

CS8124 Tuple must contain at least two elements.

CS1026 ) expected
**/

Comments

Sign In or Register to comment.