Skip to content

Commit

Permalink
Fixed final load issues with newer PHP constructs, including with use,
Browse files Browse the repository at this point in the history
…resolves #10
  • Loading branch information
mahills committed Dec 23, 2017
1 parent 482e3eb commit 8f57b1e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lang/php/ast/AbstractSyntax.rsc
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public data ClosureUse = closureUse(Expr varName, bool byRef);

public data IncludeType = include() | includeOnce() | require() | requireOnce();

public data PHPType = nullableType(str typeName) | regularType(str typeName) | noType();
public data PHPType = nullableType(PHPType nestedType) | regularType(Name typeName) | noType();

// NOTE: In PHP, yield is a statement, but it can also be used as an expression.
// To handle this, we just treat it as an expression. The parser does this as well.
Expand Down Expand Up @@ -135,7 +135,7 @@ public data Stmt
| tryCatch(list[Stmt] body, list[Catch] catches)
| tryCatchFinally(list[Stmt] body, list[Catch] catches, list[Stmt] finallyBody)
| unset(list[Expr] unsetVars)
| use(list[Use] uses, OptionName prefix, UseType useType)
| useStmt(list[Use] uses, UseType useType)
| \while(Expr cond, list[Stmt] body)
| emptyStmt()
| block(list[Stmt] body)
Expand Down

0 comments on commit 8f57b1e

Please sign in to comment.