Package net.hydromatic.morel.ast
Class Core.Pat
java.lang.Object
net.hydromatic.morel.ast.AstNode
net.hydromatic.morel.ast.Core.BaseNode
net.hydromatic.morel.ast.Core.Pat
- Direct Known Subclasses:
Core.Con0Pat,Core.ConPat,Core.ListPat,Core.LiteralPat,Core.NamedPat,Core.RecordPat,Core.TuplePat,Core.WildcardPat
- Enclosing class:
Core
Base class for a pattern.
For example, "x" in "val x = 5" is a Core.IdPat;
the "(x, y) in "val (x, y) = makePair 1 2" is a Core.TuplePat.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract Core.PatAccepts a shuttle, calling theShuttle.visit(net.hydromatic.morel.ast.Ast.Literal)method appropriate to the type of this node, and returning the result.type()Returns the type.typeKey()Returns the type's key.Methods inherited from class net.hydromatic.morel.ast.Core.BaseNode
accept
-
Field Details
-
type
-
-
Constructor Details
-
Pat
-
-
Method Details
-
type
Returns the type. -
typeKey
Returns the type's key. -
accept
Description copied from class:AstNodeAccepts a shuttle, calling theShuttle.visit(net.hydromatic.morel.ast.Ast.Literal)method appropriate to the type of this node, and returning the result.- Overrides:
acceptin classCore.BaseNode
-