Uses of Class
net.hydromatic.morel.ast.Ast.Pat
-
Packages that use Ast.Pat Package Description net.hydromatic.morel.ast Abstract syntax tree.net.hydromatic.morel.compile Validates programs (represented asAstNode), deduces their type, and compiles them into code that can be evaluated. -
-
Uses of Ast.Pat in net.hydromatic.morel.ast
Subclasses of Ast.Pat in net.hydromatic.morel.ast Modifier and Type Class Description static classAst.AnnotatedPatPattern that is a pattern annotated with a type.static classAst.AsPatLayered pattern.static classAst.Con0PatType constructor pattern with no argument.static classAst.ConPatType constructor pattern with an argument.static classAst.IdPatNamed pattern, the pattern analog of theAst.Idexpression.static classAst.InfixPatPattern build from an infix operator applied to two patterns.static classAst.ListPatList pattern, the pattern analog of theAst.ListExpexpression.static classAst.LiteralPatLiteral pattern, the pattern analog of theAst.Literalexpression.static classAst.RecordPatRecord pattern.static classAst.TuplePatTuple pattern, the pattern analog of theAst.Tupleexpression.static classAst.WildcardPatWildcard pattern.Fields in net.hydromatic.morel.ast declared as Ast.Pat Modifier and Type Field Description Ast.PatAst.InfixPat. p0Ast.PatAst.InfixPat. p1Ast.PatAst.AnnotatedPat. patAst.PatAst.AsPat. patAst.PatAst.ConPat. patAst.PatAst.Match. patAst.PatAst.Scan. patAst.PatAst.ValBind. patFields in net.hydromatic.morel.ast with type parameters of type Ast.Pat Modifier and Type Field Description List<Ast.Pat>Ast.ListPat. argsSortedMap<String,Ast.Pat>Ast.RecordPat. argsList<Ast.Pat>Ast.TuplePat. argsList<Ast.Pat>Ast.FunMatch. patListMethods in net.hydromatic.morel.ast that return Ast.Pat Modifier and Type Method Description Ast.PatAst.AnnotatedPat. accept(Shuttle shuttle)Ast.PatAst.AsPat. accept(Shuttle shuttle)Ast.PatAst.Con0Pat. accept(Shuttle shuttle)Ast.PatAst.ConPat. accept(Shuttle shuttle)Ast.PatAst.IdPat. accept(Shuttle shuttle)Ast.PatAst.InfixPat. accept(Shuttle shuttle)Ast.PatAst.ListPat. accept(Shuttle shuttle)Ast.PatAst.LiteralPat. accept(Shuttle shuttle)abstract Ast.PatAst.Pat. accept(Shuttle shuttle)Ast.PatAst.RecordPat. accept(Shuttle shuttle)Ast.PatAst.TuplePat. accept(Shuttle shuttle)Ast.PatAst.WildcardPat. accept(Shuttle shuttle)Ast.PatAstBuilder. idPat(Pos pos, String name)protected Ast.PatShuttle. visit(Ast.AnnotatedPat annotatedPat)protected Ast.PatShuttle. visit(Ast.AsPat asPat)protected Ast.PatShuttle. visit(Ast.IdPat idPat)protected Ast.PatShuttle. visit(Ast.InfixPat infixPat)protected Ast.PatShuttle. visit(Ast.ListPat listPat)protected Ast.PatShuttle. visit(Ast.LiteralPat literalPat)protected Ast.PatShuttle. visit(Ast.RecordPat recordPat)protected Ast.PatShuttle. visit(Ast.TuplePat tuplePat)protected Ast.PatShuttle. visit(Ast.WildcardPat wildcardPat)Methods in net.hydromatic.morel.ast with parameters of type Ast.Pat Modifier and Type Method Description Ast.AnnotatedPatAstBuilder. annotatedPat(Pos pos, Ast.Pat pat, Ast.Type type)Ast.AsPatAstBuilder. asPat(Pos pos, Ast.IdPat id, Ast.Pat pat)Ast.ConPatAstBuilder. conPat(Pos pos, Ast.Id tyCon, Ast.Pat pat)Ast.InfixPatAstBuilder. consPat(Ast.Pat p0, Ast.Pat p1)Ast.AnnotatedPatAst.AnnotatedPat. copy(Ast.Pat pat, Ast.Type type)Creates a copy of thisAnnotatedPatwith given contents, orthisif the contents are the same.Ast.AsPatAst.AsPat. copy(Ast.IdPat id, Ast.Pat pat)Creates a copy of thisAsPatwith given contents, orthisif the contents are the same.Ast.ConPatAst.ConPat. copy(Ast.Id tyCon, Ast.Pat pat)Creates a copy of thisConPatwith given contents, orthisif the contents are the same.Ast.InfixPatAst.InfixPat. copy(Ast.Pat p0, Ast.Pat p1)Creates a copy of thisInfixPatwith given contents and same operator, orthisif the contents are the same.Ast.MatchAst.Match. copy(Ast.Pat pat, Ast.Exp exp)Creates a copy of thisMatchwith given contents, orthisif the contents are the same.Ast.ScanAst.Scan. copy(Ast.Pat pat, Ast.Exp exp, Ast.Exp condition)Ast.ValBindAst.ValBind. copy(Ast.Pat pat, Ast.Exp exp)Creates a copy of thisValBindwith given contents, orthisif the contents are the same.Ast.InfixPatAstBuilder. infixPat(Pos pos, Op op, Ast.Pat p0, Ast.Pat p1)Ast.ListPatAstBuilder. listPat(Pos pos, Ast.Pat... args)Ast.MatchAstBuilder. match(Pos pos, Ast.Pat pat, Ast.Exp exp)Ast.ScanAstBuilder. scan(Pos pos, Op op, Ast.Pat pat, Ast.Exp exp, Ast.Exp condition)Ast.TuplePatAstBuilder. tuplePat(Pos pos, Ast.Pat... args)Ast.ValBindAstBuilder. valBind(Pos pos, Ast.Pat pat, Ast.Exp exp)Method parameters in net.hydromatic.morel.ast with type arguments of type Ast.Pat Modifier and Type Method Description Ast.ListPatAst.ListPat. copy(List<Ast.Pat> args)Creates a copy of thisListPatwith given contents, orthisif the contents are the same.Ast.RecordPatAst.RecordPat. copy(boolean ellipsis, Map<String,? extends Ast.Pat> args)Ast.TuplePatAst.TuplePat. copy(List<Ast.Pat> args)Creates a copy of thisTuplePatwith given contents, orthisif the contents are the same.voidAst.AnnotatedPat. forEachArg(ObjIntConsumer<Ast.Pat> action)voidAst.AsPat. forEachArg(ObjIntConsumer<Ast.Pat> action)voidAst.ConPat. forEachArg(ObjIntConsumer<Ast.Pat> action)voidAst.InfixPat. forEachArg(ObjIntConsumer<Ast.Pat> action)voidAst.ListPat. forEachArg(ObjIntConsumer<Ast.Pat> action)voidAst.Pat. forEachArg(ObjIntConsumer<Ast.Pat> action)voidAst.RecordPat. forEachArg(ObjIntConsumer<Ast.Pat> action)voidAst.TuplePat. forEachArg(ObjIntConsumer<Ast.Pat> action)Ast.FunMatchAstBuilder. funMatch(Pos pos, String name, Iterable<? extends Ast.Pat> patList, Ast.Type returnType, Ast.Exp exp)Ast.ListPatAstBuilder. listPat(Pos pos, Iterable<? extends Ast.Pat> args)Ast.RecordPatAstBuilder. recordPat(Pos pos, boolean ellipsis, Map<String,? extends Ast.Pat> args)Ast.TuplePatAstBuilder. tuplePat(Pos pos, Iterable<? extends Ast.Pat> args)voidAst.Pat. visit(Consumer<Ast.Pat> consumer)Constructors in net.hydromatic.morel.ast with parameters of type Ast.Pat Constructor Description AnnotatedPat(Pos pos, Ast.Pat pat, Ast.Type type)AsPat(Pos pos, Ast.IdPat id, Ast.Pat pat)ConPat(Pos pos, Ast.Id tyCon, Ast.Pat pat)InfixPat(Pos pos, Op op, Ast.Pat p0, Ast.Pat p1)Match(Pos pos, Ast.Pat pat, Ast.Exp exp)Scan(Pos pos, Op op, Ast.Pat pat, Ast.Exp exp, @Nullable Ast.Exp condition)ValBind(Pos pos, Ast.Pat pat, Ast.Exp exp)Constructor parameters in net.hydromatic.morel.ast with type arguments of type Ast.Pat Constructor Description FunMatch(Pos pos, String name, com.google.common.collect.ImmutableList<Ast.Pat> patList, @Nullable Ast.Type returnType, Ast.Exp exp)ListPat(Pos pos, com.google.common.collect.ImmutableList<Ast.Pat> args)RecordPat(Pos pos, boolean ellipsis, com.google.common.collect.ImmutableSortedMap<String,Ast.Pat> args)TuplePat(Pos pos, com.google.common.collect.ImmutableList<Ast.Pat> args) -
Uses of Ast.Pat in net.hydromatic.morel.compile
Methods in net.hydromatic.morel.compile that return Ast.Pat Modifier and Type Method Description private Ast.PatTypeResolver. deducePatType(TypeResolver.TypeEnv env, Ast.Pat pat, Map<Ast.IdPat,Unifier.Term> termMap, NavigableSet<String> labelNames, Unifier.Variable v)Derives a type term for a pattern, collecting the names of pattern variables.private Ast.PatTypeResolver. patTuple(TypeResolver.TypeEnv env, List<Ast.Pat> patList)Converts a list of patterns to a singleton pattern or tuple pattern.Methods in net.hydromatic.morel.compile with parameters of type Ast.Pat Modifier and Type Method Description private Ast.PatTypeResolver. deducePatType(TypeResolver.TypeEnv env, Ast.Pat pat, Map<Ast.IdPat,Unifier.Term> termMap, NavigableSet<String> labelNames, Unifier.Variable v)Derives a type term for a pattern, collecting the names of pattern variables.private voidResolver. flatten(Map<Ast.Pat,Ast.Exp> matches, boolean flatten, Ast.Pat pat, Ast.Exp exp)private Core.PatResolver. toCore(Ast.Pat pat)private Core.PatResolver. toCore(Ast.Pat pat, Type targetType)private Core.PatResolver. toCore(Ast.Pat pat, Type type, Type targetType)Converts a pattern to Core.Method parameters in net.hydromatic.morel.compile with type arguments of type Ast.Pat Modifier and Type Method Description private voidResolver. flatten(Map<Ast.Pat,Ast.Exp> matches, boolean flatten, Ast.Pat pat, Ast.Exp exp)private Ast.PatTypeResolver. patTuple(TypeResolver.TypeEnv env, List<Ast.Pat> patList)Converts a list of patterns to a singleton pattern or tuple pattern.
-