This commit is contained in:
parent
acab4c7c01
commit
dbf22ca9e8
|
|
@ -129,7 +129,7 @@ namespace SyntaxVisitors
|
|||
|
||||
Replace(var_def, newVS);
|
||||
listNodes[listNodes.Count - 1] = newVS; //SSM 8.11.18
|
||||
ProcessNode(newVS.inital_value); // SSM 10.06.2020 #2103
|
||||
//ProcessNode(newVS.inital_value); // SSM 10.06.2020 #2103
|
||||
//base.visit(newVS); // SSM 10.06.2020 - зачем обходить всё?
|
||||
}
|
||||
|
||||
|
|
|
|||
17
TestSuite/yield8.pas
Normal file
17
TestSuite/yield8.pas
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
function V(n: byte) := 1;
|
||||
|
||||
function f1: sequence of integer;
|
||||
begin
|
||||
//Ошибка: Ожидалось имя процедуры или функции
|
||||
var v := V(0);
|
||||
|
||||
// Если закомментировать эту строчку - предыдущая строчка работает
|
||||
yield v;
|
||||
end;
|
||||
|
||||
begin
|
||||
var i := 0;
|
||||
foreach var j in f1 do
|
||||
i := j;
|
||||
assert(i = 1);
|
||||
end.
|
||||
Loading…
Reference in a new issue