GlobalTypePass

class GlobalTypePass: ITypePass, Any

Builds all types which will be considered as global types e.g. int, array types e.g. java.lang.String[].

Constructors

<init>

constructor(driver: IDriver)

Builds all types which will be considered as global types e.g. int, array types e.g. java.lang.String[].

Parameters

Name Description
driver: IDriver

Methods

runPass

fun runPass(ts: List<Type>): List<Type>

Creates a global TYPE_DECL and connects it to the global namespace block. i.e

    NAMESPACE_BLOCK() -(AST)-> TYPE_DECL
    FILE() -(CONTAINS)-> TYPE_DECL
    FILE() <-(SOURCE_FILE)- TYPE_DECL
    TYPE -(REF)-> TYPE_DECL
    TYPE_DECL -(AST)-> *MEMBER ? String[].length ? (TO-DO:)
    TYPE_DECL -(AST)-> *MODIFIER ?

Parameters

Name Description
ts: List<Type>

ReturnValue

Name Description
List<Type>