mirror of
git://source.winehq.org/git/wine.git
synced 2024-10-14 09:41:41 +00:00
vbscript: Fix compile when statement after ElseIf or after separator.
This commit is contained in:
parent
aa7a6b8f42
commit
887e72b24e
|
@ -314,7 +314,7 @@ ElseIfs
|
|||
| ElseIf ElseIfs { $1->next = $2; $$ = $1; }
|
||||
|
||||
ElseIf
|
||||
: tELSEIF Expression tTHEN tNL StatementsNl_opt
|
||||
: tELSEIF Expression tTHEN StSep_opt StatementsNl_opt
|
||||
{ $$ = new_elseif_decl(ctx, @$, $2, $5); }
|
||||
|
||||
Else_opt
|
||||
|
|
|
@ -337,6 +337,23 @@ ElseIf not False Then
|
|||
End If
|
||||
Call ok(x, "elseif not called?")
|
||||
|
||||
' ElseIf with statement on same line
|
||||
x = false
|
||||
If false Then
|
||||
Call ok(false, "inside if false")
|
||||
ElseIf not False Then x = true
|
||||
End If
|
||||
Call ok(x, "elseif not called?")
|
||||
|
||||
' ElseIf with statement following statement separator
|
||||
x = false
|
||||
If false Then
|
||||
Call ok(false, "inside if false")
|
||||
ElseIf not False Then
|
||||
: x = true
|
||||
End If
|
||||
Call ok(x, "elseif not called?")
|
||||
|
||||
x = false
|
||||
if 1 then x = true
|
||||
Call ok(x, "if 1 not run?")
|
||||
|
|
Loading…
Reference in a new issue