Package hydra.ext.haskell
Interface Coder
-
public interface CoderFunctions for encoding Hydra modules as Haskell modules
-
-
Method Summary
-
-
-
Method Detail
-
adaptTypeToHaskellAndEncode
static <T0> Either<InContext<Error_>,Type> adaptTypeToHaskellAndEncode(Namespaces<ModuleName> namespaces, Type typ, Context cx, T0 g)
-
constantForTypeName
static java.lang.String constantForTypeName(Name tname)
-
constructModule
static Either<InContext<Error_>,Module> constructModule(Namespaces<ModuleName> namespaces, Module mod, ConsList<Definition> defs, Context cx, Graph g)
-
encodeCaseExpression
static Either<InContext<Error_>,Expression> encodeCaseExpression(java.lang.Integer depth, Namespaces<ModuleName> namespaces, CaseStatement stmt, Expression scrutinee, Context cx, Graph g)
-
encodeCaseExpression_noArgs
static <T0> ConsList<T0> encodeCaseExpression_noArgs()
-
encodeFunction
static Either<InContext<Error_>,Expression> encodeFunction(java.lang.Integer depth, Namespaces<ModuleName> namespaces, Function fun, Context cx, Graph g)
-
encodeTerm
static Either<InContext<Error_>,Expression> encodeTerm(java.lang.Integer depth, Namespaces<ModuleName> namespaces, Term term, Context cx, Graph g)
-
encodeType
static <T0> Either<InContext<Error_>,Type> encodeType(Namespaces<ModuleName> namespaces, Type typ, Context cx, T0 g)
-
encodeTypeWithClassAssertions
static <T0> Either<InContext<Error_>,Type> encodeTypeWithClassAssertions(Namespaces<ModuleName> namespaces, PersistentMap<Name,PersistentSet<TypeClass>> explicitClasses, Type typ, Context cx, T0 g)
-
encodeTypeWithClassAssertions_clsSet
static <T1,T2> PersistentSet<T2> encodeTypeWithClassAssertions_clsSet(Pair<T1,PersistentSet<T2>> mapEntry)
-
encodeTypeWithClassAssertions_name
static <T1,T2> T1 encodeTypeWithClassAssertions_name(Pair<T1,PersistentSet<T2>> mapEntry)
-
encodeTypeWithClassAssertions_toPair
static <T1,T2,T3> Pair<T1,T3> encodeTypeWithClassAssertions_toPair(Pair<T1,PersistentSet<T2>> mapEntry, T3 c)
-
encodeTypeWithClassAssertions_toPairs
static <T1,T2> ConsList<Pair<T1,T2>> encodeTypeWithClassAssertions_toPairs(Pair<T1,PersistentSet<T2>> mapEntry)
-
encodeType_ref
static <T1> Either<T1,Type> encodeType_ref(java.util.function.Function<Namespaces<ModuleName>,java.util.function.Function<Name,Name>> hydra_ext_haskell_utils_elementReference2, Namespaces<ModuleName> namespaces, Name name)
-
findOrdVariables
static PersistentSet<Name> findOrdVariables(Type typ)
-
getImplicitTypeClasses
static PersistentMap<Name,PersistentSet<TypeClass>> getImplicitTypeClasses(Type typ)
-
getImplicitTypeClasses_toPair
static <T0> Pair<T0,PersistentSet<TypeClass>> getImplicitTypeClasses_toPair(T0 name)
-
includeTypeDefinitions
static java.lang.Boolean includeTypeDefinitions()
-
keyHaskellVar
static Name keyHaskellVar()
-
moduleToHaskell
static Either<InContext<Error_>,PersistentMap<java.lang.String,java.lang.String>> moduleToHaskell(Module mod, ConsList<Definition> defs, Context cx, Graph g)
-
moduleToHaskellModule
static Either<InContext<Error_>,Module> moduleToHaskellModule(Module mod, ConsList<Definition> defs, Context cx, Graph g)
-
nameDecls
static ConsList<DeclarationWithComments> nameDecls(Namespaces<ModuleName> namespaces, Name name, Type typ)
-
toDataDeclaration
static Either<InContext<Error_>,DeclarationWithComments> toDataDeclaration(Namespaces<ModuleName> namespaces, TermDefinition def, Context cx, Graph g)
-
toTypeDeclarationsFrom
static Either<InContext<Error_>,ConsList<DeclarationWithComments>> toTypeDeclarationsFrom(Namespaces<ModuleName> namespaces, Name elementName, Type typ, Context cx, Graph g)
-
typeDecl
static Either<InContext<Error_>,DeclarationWithComments> typeDecl(Namespaces<ModuleName> namespaces, Name name, Type typ, Context cx, Graph g)
-
typeSchemeConstraintsToClassMap
static <T0> PersistentMap<T0,PersistentSet<TypeClass>> typeSchemeConstraintsToClassMap(Maybe<PersistentMap<T0,TypeVariableMetadata>> maybeConstraints)
-
useCoreImport
static java.lang.Boolean useCoreImport()
-
-