Skip to main content Module ast Copy item path Source ArenaVec Arena-allocated Vec. Thin newtype over bumpalo::collections::Vec that implements Serialize and Debug. Arg ArrayAccessExpr ArrayElement ArrowFunctionExpr AssignExpr Attribute BinaryExpr Block A brace-delimited statement block. Used both as a standalone block
statement (StmtKind::Block ) and as the body of constructs that are
always braced (functions, methods, closures, try/catch/finally,
braced namespaces, property-hook blocks) — those positions hold a
&Block so the “it’s a block” invariant is enforced by the type. CallableCreateExpr CatchClause ClassBody ClassConstDecl ClassDecl ClassMember ClassModifiers ClosureExpr ClosureUseVar Comment A comment found in the source file. ConstItem DeclareStmt DoWhileStmt ElseIfBranch EnumBody EnumCase EnumDecl EnumMember Expr ForStmt ForeachStmt FunctionCallExpr FunctionDecl Ident A bare identifier — the kind that names a function, class, parameter,
enum case, etc. Distinct from Name , which represents possibly-qualified
names. IfStmt InterfaceDecl MatchArm MatchExpr MethodCallExpr MethodDecl NameStr A name string from either the source buffer or the bump arena. Use as_str
or Deref to get the string value — the allocation origin is an internal parser detail. NamespaceDecl NewExpr NullCoalesceExpr Param Program The root AST node representing a complete PHP file. PropertyAccessExpr PropertyDecl PropertyHook StaticAccessExpr StaticDynMethodCallExpr StaticMethodCallExpr StaticVar Stmt SwitchBody SwitchCase SwitchStmt TernaryExpr TraitAdaptation TraitDecl TraitUseDecl TryCatchStmt TypeHint UnaryPostfixExpr UnaryPrefixExpr UseDecl UseItem WhileStmt YieldExpr AssignOp BinaryOp BuiltinType PHP built-in type keyword — zero-cost alternative to Name::Simple for the
20 reserved type names. One byte instead of a Cow<str> + Span in the AST. CallableCreateKind CastKind ClassMemberKind CommentKind Distinguishes the four syntactic forms of PHP comment. EnumMemberKind ExprKind IncludeKind MagicConstKind Name A PHP name (identifier, qualified name, fully-qualified name, or relative name). NameKind NamespaceBody PropertyHookBody PropertyHookKind StmtKind StringPart TraitAdaptationKind TypeHintKind A PHP type hint. UnaryPostfixOp UnaryPrefixOp UseKind Visibility