diff options
author | Rico Tzschichholz <ricotz@ubuntu.com> | 2021-02-16 10:33:06 +0100 |
---|---|---|
committer | Rico Tzschichholz <ricotz@ubuntu.com> | 2021-02-16 10:33:06 +0100 |
commit | 2e9b53c44c6550aab73ace8a1d995c16c152577a (patch) | |
tree | d848539418bb16cac82e697fee4928403eda319e /vala/valaloopstatement.vala | |
parent | 2203158754e20dd4dbd2b70bb069ff408c7e1504 (diff) | |
download | vala-2e9b53c44c6550aab73ace8a1d995c16c152577a.tar.gz |
codewriter: Output valid vala syntax for LoopStatement
Diffstat (limited to 'vala/valaloopstatement.vala')
-rw-r--r-- | vala/valaloopstatement.vala | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/vala/valaloopstatement.vala b/vala/valaloopstatement.vala index 8348d300c..e522fd1b0 100644 --- a/vala/valaloopstatement.vala +++ b/vala/valaloopstatement.vala @@ -34,7 +34,7 @@ public class Vala.LoopStatement : Loop, Statement { * @return newly created while statement */ public LoopStatement (Block body, SourceReference? source_reference = null) { - base (null, body, source_reference); + base (new BooleanLiteral (true, source_reference), body, source_reference); } public override void accept (CodeVisitor visitor) { @@ -56,6 +56,7 @@ public class Vala.LoopStatement : Loop, Statement { checked = true; + condition.check (context); body.check (context); return !error; |