java.lang.Object
antlr.TreeParser
de.grogra.xl.compiler.CompilerBase
- All Implemented Interfaces:
CompilerTokenTypes,Members.Resolution
- Direct Known Subclasses:
Compiler
public abstract class CompilerBase
extends antlr.TreeParser
implements CompilerTokenTypes, Members.Resolution
This helper class is the superclass of
Compiler.
Its members would normally be declared in Compiler. However,
since the latter class is generated by ANTLR from a grammar file, it is
more convenient to extract these members to a helper class which is defined
by this conventional Java source file.- Author:
- Ole Kniemeyer
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intConstant forrunindicating the third, final run.Stores the current CompilationUnitScope, if one was set.static final intstatic final intstatic final I18NBundleResource bundle for messages.static final intConstant forrunindicating the second run.static final longstatic final longstatic final longstatic final longstatic final longstatic final longstatic final longstatic final longstatic final longstatic final longstatic final longstatic final longstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final longstatic final intConstant forrunindicating the first run.static final longFields inherited from class antlr.TreeParser
_retTree, astFactory, ASTNULL, inputState, returnAST, tokenNames, traceDepthFields inherited from interface de.grogra.xl.compiler.CompilerTokenTypes
ABSTRACT_, ADD, ADD_ASSIGN, AND, AND_ASSIGN, ANNOTATION, ANY, APPLICATION_CONDITION, ARGLIST, ARRAY_DECLARATOR, ARRAY_INIT, ARRAY_ITERATOR, ARROW, ASSERT, ASSIGN, BOOLEAN_, BOOLEAN_LITERAL, BREAK, BYTE_, CAND, CASE, CATCH, CHAR_, CHAR_LITERAL, CLASS, CLASS_LITERAL, CMP, COM, COMPILATION_UNIT, COMPOUND_PATTERN, CONST_, CONSTRUCTOR, CONTEXT, CONTINUE, COR, DEC, DECLARING_TYPE, DEFAULT, DEFERRED_ADD, DEFERRED_AND, DEFERRED_ASSIGN, DEFERRED_DIV, DEFERRED_MUL, DEFERRED_OR, DEFERRED_POW, DEFERRED_RATE_ASSIGN, DEFERRED_REM, DEFERRED_SHL, DEFERRED_SHR, DEFERRED_SUB, DEFERRED_USHR, DEFERRED_XOR, DIMLIST, DIV, DIV_ASSIGN, DO, DOT, DOUBLE_, DOUBLE_ARROW_RULE, DOUBLE_LITERAL, ELIST, EMPTY, ENHANCED_FOR, EOF, EQUALS, EXEC_RULE, EXPR, EXTENDS, EXTENT_VISIBILITY, FINAL_, FINALLY, FLOAT_, FLOAT_LITERAL, FOLDING, FOR, GE, GLOBAL_, GT, GUARD, IDENT, IF, IMPLEMENTS, IMPORT_ON_DEMAND, IN, INC, INDEX_OP, INSTANCE_INIT, INSTANCEOF, INSTANTIATOR, INT_, INT_LITERAL, INTERFACE, INVALID_EXPR, INVOKE_OP, ITERATING_, LABEL, LABELED_STATEMENT, LATE_MATCH, LCLIQUE, LE, LEFT_ARROW, LEFT_RIGHT_ARROW, LINE, LONG_, LONG_ARROW, LONG_LEFT_ARROW, LONG_LEFT_RIGHT_ARROW, LONG_LITERAL, LT, MARKER, METHOD, METHOD_CALL, METHOD_PATTERN, MINIMAL, MODIFIERS, MODULE, MUL, MUL_ASSIGN, NAME_PATTERN, NATIVE_, NEG, NEW, NODE, NODES, NORMAL, NOT, NOT_EQUALS, NULL_LITERAL, NULL_TREE_LOOKAHEAD, OPTIONAL_MATCH, OR, OR_ASSIGN, PACKAGE, PARAMETER_DEF, PARAMETERIZED_PATTERN, PARAMETERS, PATTERN_WITH_BLOCK, PLUS_ARROW, PLUS_LEFT_ARROW, PLUS_LEFT_RIGHT_ARROW, PLUS_LINE, POS, POST_DEC, POST_INC, POW, POW_ASSIGN, PRIVATE_, PRODUCE, PROTECTED_, PUBLIC_, QUALIFIED_NEW, QUALIFIED_SUPER, QUERY, QUERY_EXPR, QUESTION, QUOTE, RANGE, RANGE_EXACTLY, RANGE_MIN, RCLIQUE, REM, REM_ASSIGN, RETURN, ROOT, RULE, RULE_BLOCK, SCALE, SEMI, SEPARATE, SHELL_BLOCK, SHL, SHL_ASSIGN, SHORT_, SHR, SHR_ASSIGN, SINGLE_ELEMENT, SINGLE_MATCH, SINGLE_OPTIONAL_MATCH, SINGLE_STATIC_IMPORT, SINGLE_TYPE_IMPORT, SLASH_ARROW, SLASH_LEFT_ARROW, SLASH_LEFT_RIGHT_ARROW, SLASH_LINE, SLIST, STATIC_, STATIC_IMPORT_ON_DEMAND, STATIC_INIT, STATIC_MEMBER_CLASSES, STRICT_, STRING_LITERAL, SUB, SUB_ASSIGN, SUPER, SWITCH, SWITCH_GROUP, SYNCHRONIZED_, THIS, THROW, THROWS, TRANSIENT_, TRAVERSAL, TREE, TRY, TYPE_PATTERN, TYPECAST, TYPECHECK, UNARY_PREFIX, USHR, USHR_ASSIGN, VARARGS_, VARIABLE_DEF, VOID_, VOLATILE_, WHILE, WITH, WRAPPED_TYPE_PATTERN, X_LEFT_RIGHT_ARROW, XOR, XOR_ASSIGN, YIELD -
Method Summary
Modifier and TypeMethodDescriptionbooleanallowsAmbiguousMembers(Member first) Defines if ambiguous members are allowed.assignmentConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos) castingConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos) castingConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos, String msg, boolean test) static voidcheckOperatorFunction(antlr.collections.AST params, antlr.collections.AST mods, antlr.collections.AST id, int symbol, RecognitionExceptionList exceptionList) compile(CompilationUnit[] units, CClass shell, BytecodeWriter writer, FileSystem fs, Object dir, boolean keepExpressions) protected abstract CompilationUnitScopecompile(ClassPath classPath, antlr.collections.AST tree, String source, Scope defaultImports, Annotation[] annotations, CClass shell) compileFieldExpression(Field field, Expression expr, Scope scope, antlr.collections.AST pos) compileInstance(Member m, Scope declaring, Scope s, antlr.collections.AST pos) static voidcopyInfo(Expression src, Expression dest) <T> TcreateModel(Class<T> type, Type<?> model, antlr.collections.AST pos) void<T extends Annotation>
Annotation<T> getAnnotation(Member member, Class<T> cls, boolean inherited) Type[]Returns the argument types which are used inMembers.Resolution.isApplicable(Member, Members.Applicability, Scope)to determine the applicability.static antlr.collections.ASTgetAST(Expression e) static BlockScopeReturn the current value of theCompilationUnitScope.Return the package name to use as default.Returns the package of the current compilation unit.intgetRun()Returns the current run of the compiler.Return the current value of theTypeScope.getWrapperTypeFor(Type type, CompiletimeModel model, antlr.collections.AST pos) implicitConversion(Expression expr, Type type, boolean allowD2F, Scope scope, antlr.collections.AST pos, String msg, boolean test) Perform autoconversion of the expression to target type.voidintersect(IntersectionType intersection, Type newType, antlr.collections.AST pos) booleanisApplicable(Member m, Members.Applicability appl, Scope scope) Checks whether a membermis applicable.booleanisLessThan(Member m1, Members.Applicability a1, Member m2, Members.Applicability a2, Scope scope) Checks whether an applicable memberm1is less specific than another applicable memberm2.methodInvocationConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos) static final StringmodifiersToString(long mods) returnConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos) static ExpressionsetAST(Expression e, antlr.collections.AST ast) static voidvoidsetLegalSupertype(Type lst) voidsetVerbose(PrintWriter out) standardImplicitConversion(Expression expr, Type type, boolean allowD2F, Scope scope, antlr.collections.AST pos, String msg, boolean test) Perform autoconversion of the expression to target type.booleansupportsVersion(int ver) Returns true if the specified version number designates a version of the JVM that is compatible with the target version currently set.typeForType(Type type) verifyNotDeclared(antlr.collections.AST name, BlockScope s) verifyNotDeclared(String name, BlockScope s, antlr.collections.AST pos) wideningConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos) Methods inherited from class antlr.TreeParser
getAST, getASTFactory, getTokenName, getTokenNames, match, match, matchNot, panic, reportError, reportError, reportWarning, setASTFactory, setASTNodeClass, setASTNodeType, traceIn, traceIndent, traceOut
-
Field Details
-
I18N
Resource bundle for messages. -
TYPE_AND_FIELD_DECLARATION
public static final int TYPE_AND_FIELD_DECLARATIONConstant forrunindicating the first run. In this run, type and field declarations are processed.- See Also:
-
METHOD_DECLARATION
public static final int METHOD_DECLARATIONConstant forrunindicating the second run. In this run, method and constructor declarations are processed.- See Also:
-
COMPILATION
public static final int COMPILATIONConstant forrunindicating the third, final run. In this run, the actual expressions and statements are compiled.- See Also:
-
currentCompilationUnitScope
Stores the current CompilationUnitScope, if one was set. This field is set during parsing, so see Compiler.tree.g. -
options
-
EXPR_FINAL
public static final int EXPR_FINAL- See Also:
-
EXPR_THIS
public static final int EXPR_THIS- See Also:
-
MOD_ITERATING
public static final long MOD_ITERATING- See Also:
-
MOD_PARAMETER
public static final long MOD_PARAMETER- See Also:
-
MOD_ROUTINE
public static final long MOD_ROUTINE- See Also:
-
MOD_CONSTRUCTOR
public static final long MOD_CONSTRUCTOR- See Also:
-
MOD_THIS_PARAMETER
public static final long MOD_THIS_PARAMETER- See Also:
-
MOD_INITIALIZER
public static final long MOD_INITIALIZER- See Also:
-
MOD_CONST
public static final long MOD_CONST- See Also:
-
MOD_INSTANTIATOR
public static final long MOD_INSTANTIATOR- See Also:
-
MOD_MODULE
public static final long MOD_MODULE- See Also:
-
MOD_IMPLICIT_ARGUMENT
public static final long MOD_IMPLICIT_ARGUMENT- See Also:
-
MOD_STATIC_MEMBER_CLASSES
public static final long MOD_STATIC_MEMBER_CLASSES- See Also:
-
MOD_GLOBAL
public static final long MOD_GLOBAL- See Also:
-
ROUTINE_MODIFIERS
public static final long ROUTINE_MODIFIERS- See Also:
-
problems
-
WARN_ON_IMPLICIT_MODIFIER
public static final long WARN_ON_IMPLICIT_MODIFIER- See Also:
-
PRODUCER_GET_ROOT
- See Also:
-
PRODUCER_BEGIN
- See Also:
-
PRODUCER_END
- See Also:
-
PRODUCER_PUSH
- See Also:
-
PRODUCER_POP
- See Also:
-
PRODUCER_SEPARATE
- See Also:
-
PRODUCER_CLIQUE_BEGIN
- See Also:
-
PRODUCER_CLIQUE_END
- See Also:
-
OPERATOR_NAME_NEG
- See Also:
-
OPERATOR_NAME_POS
- See Also:
-
OPERATOR_NAME_NOT
- See Also:
-
OPERATOR_NAME_COM
- See Also:
-
OPERATOR_NAME_INC
- See Also:
-
OPERATOR_NAME_DEC
- See Also:
-
OPERATOR_NAME_POST_INC
- See Also:
-
OPERATOR_NAME_POST_DEC
- See Also:
-
OPERATOR_NAME_ADD
- See Also:
-
OPERATOR_NAME_SUB
- See Also:
-
OPERATOR_NAME_MUL
- See Also:
-
OPERATOR_NAME_DIV
- See Also:
-
OPERATOR_NAME_REM
- See Also:
-
OPERATOR_NAME_POW
- See Also:
-
OPERATOR_NAME_COR
- See Also:
-
OPERATOR_NAME_CAND
- See Also:
-
OPERATOR_NAME_ADD_ASSIGN
- See Also:
-
OPERATOR_NAME_SUB_ASSIGN
- See Also:
-
OPERATOR_NAME_MUL_ASSIGN
- See Also:
-
OPERATOR_NAME_DIV_ASSIGN
- See Also:
-
OPERATOR_NAME_REM_ASSIGN
- See Also:
-
OPERATOR_NAME_POW_ASSIGN
- See Also:
-
OPERATOR_NAME_SHL
- See Also:
-
OPERATOR_NAME_SHR
- See Also:
-
OPERATOR_NAME_USHR
- See Also:
-
OPERATOR_NAME_SHL_ASSIGN
- See Also:
-
OPERATOR_NAME_SHR_ASSIGN
- See Also:
-
OPERATOR_NAME_USHR_ASSIGN
- See Also:
-
OPERATOR_NAME_XOR
- See Also:
-
OPERATOR_NAME_OR
- See Also:
-
OPERATOR_NAME_AND
- See Also:
-
OPERATOR_NAME_XOR_ASSIGN
- See Also:
-
OPERATOR_NAME_OR_ASSIGN
- See Also:
-
OPERATOR_NAME_AND_ASSIGN
- See Also:
-
OPERATOR_NAME_EQUALS
- See Also:
-
OPERATOR_NAME_NOT_EQUALS
- See Also:
-
OPERATOR_NAME_LT
- See Also:
-
OPERATOR_NAME_LE
- See Also:
-
OPERATOR_NAME_GT
- See Also:
-
OPERATOR_NAME_GE
- See Also:
-
OPERATOR_NAME_CMP
- See Also:
-
OPERATOR_NAME_RANGE
- See Also:
-
OPERATOR_NAME_IN
- See Also:
-
OPERATOR_NAME_GUARD
- See Also:
-
OPERATOR_NAME_ARROW
- See Also:
-
OPERATOR_NAME_LEFT_ARROW
- See Also:
-
OPERATOR_NAME_LONG_ARROW
- See Also:
-
OPERATOR_NAME_LONG_LEFT_ARROW
- See Also:
-
OPERATOR_NAME_LONG_LEFT_RIGHT_ARROW
- See Also:
-
OPERATOR_NAME_PLUS_LEFT_ARROW
- See Also:
-
OPERATOR_NAME_PLUS_ARROW
- See Also:
-
OPERATOR_NAME_PLUS_LEFT_RIGHT_ARROW
- See Also:
-
OPERATOR_NAME_PLUS_LINE
- See Also:
-
OPERATOR_NAME_SLASH_LEFT_ARROW
- See Also:
-
OPERATOR_NAME_SLASH_ARROW
- See Also:
-
OPERATOR_NAME_SLASH_LEFT_RIGHT_ARROW
- See Also:
-
OPERATOR_NAME_SLASH_LINE
- See Also:
-
OPERATOR_NAME_LEFT_RIGHT_ARROW
- See Also:
-
OPERATOR_NAME_X_LEFT_RIGHT_ARROW
- See Also:
-
OPERATOR_NAME_LINE
- See Also:
-
OPERATOR_NAME_INDEX
- See Also:
-
OPERATOR_NAME_INVOKE
- See Also:
-
OPERATOR_NAME_QUOTE
- See Also:
-
OPERATOR_NAME_SPACE
- See Also:
-
OPERATOR_NAME_DEFERRED_ASSIGN
- See Also:
-
OPERATOR_NAME_DEFERRED_RATE_ASSIGN
- See Also:
-
OPERATOR_NAME_DEFERRED_POW
- See Also:
-
OPERATOR_NAME_DEFERRED_MUL
- See Also:
-
OPERATOR_NAME_DEFERRED_DIV
- See Also:
-
OPERATOR_NAME_DEFERRED_REM
- See Also:
-
OPERATOR_NAME_DEFERRED_ADD
- See Also:
-
OPERATOR_NAME_DEFERRED_SUB
- See Also:
-
OPERATOR_NAME_DEFERRED_SHL
- See Also:
-
OPERATOR_NAME_DEFERRED_SHR
- See Also:
-
OPERATOR_NAME_DEFERRED_USHR
- See Also:
-
OPERATOR_NAME_DEFERRED_AND
- See Also:
-
OPERATOR_NAME_DEFERRED_XOR
- See Also:
-
OPERATOR_NAME_DEFERRED_OR
- See Also:
-
-
Method Details
-
getRun
public int getRun()Returns the current run of the compiler. The compiler works in three runs. The return value indicates the current run.- Returns:
- current run
- See Also:
-
compile
public Object compile(ClassPath classPath, Scope defaultImports, Parser parser, CClass shell) throws IOException, RecognitionException - Throws:
IOExceptionRecognitionException
-
compile
protected abstract CompilationUnitScope compile(ClassPath classPath, antlr.collections.AST tree, String source, Scope defaultImports, Annotation[] annotations, CClass shell) throws antlr.RecognitionException - Throws:
antlr.RecognitionException
-
compile
public CompilationUnitScope[] compile(CompilationUnit[] units, CClass shell, BytecodeWriter writer, FileSystem fs, Object dir, boolean keepExpressions) throws IOException - Throws:
IOException
-
supportsVersion
public boolean supportsVersion(int ver) Returns true if the specified version number designates a version of the JVM that is compatible with the target version currently set. Valid values for the version number are the constants in org.objectweb.asm.Opcodes.V* For instance a call supportsVersion(Opcodes.V1_4) with Opcodes.V1_4 currently set as target would return true. The same call with Opcodes.V1_3 set as target would return false.- Parameters:
ver-- Returns:
-
getPackage
Returns the package of the current compilation unit.- Returns:
- current package
-
getCompilationUnitScope
Return the current value of theCompilationUnitScope.- Returns:
- current
CompilationUnitScope
-
getTypeScope
Return the current value of theTypeScope.- Returns:
- current
TypeScope
-
modifiersToString
-
copyInfo
-
setBlockScope
-
getBlockScope
-
setAST
-
getAST
-
setLegalSupertype
-
setVerbose
-
verifyNotDeclared
-
verifyNotDeclared
-
intersect
-
getWrapperTypeFor
-
castingConversion
public Expression castingConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos) -
wideningConversion
public Expression wideningConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos) -
methodInvocationConversion
public Expression methodInvocationConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos) -
assignmentConversion
public Expression assignmentConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos) -
returnConversion
public Expression returnConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos) -
typeForType
-
getAnnotation
public <T extends Annotation> Annotation<T> getAnnotation(Member member, Class<T> cls, boolean inherited) -
implicitConversion
public Expression implicitConversion(Expression expr, Type type, boolean allowD2F, Scope scope, antlr.collections.AST pos, String msg, boolean test) Perform autoconversion of the expression to target type. Autoconversion includes widening conversions, boxing and unboxing, and allows to transform an object of type A into an object of type B by means of conversion functions. Every function declared as 'static B valueOf(A)', 'static B toB(A)', 'B A.toB()' and constructors of the form 'B(A)' are considered as conversion functions. If more than one conversion from type A to type B using those conversion functions is possible, the conversion is ambiguous and results in an error.- Parameters:
expr- source expressiontype- target typescope- current scopepos- location to use for error reportsmsg- message key to use for error reportsboxOnly- only check for autoboxing/unboxing, no further autoconversions- Returns:
- auto-converted expression, or
nullif no such conversion is possible andmsgisnull
-
castingConversion
public Expression castingConversion(Expression expr, Type type, Scope scope, antlr.collections.AST pos, String msg, boolean test) -
standardImplicitConversion
public Expression standardImplicitConversion(Expression expr, Type type, boolean allowD2F, Scope scope, antlr.collections.AST pos, String msg, boolean test) Perform autoconversion of the expression to target type. Autoconversion includes widening conversions, boxing and unboxing, and allows to transform an object of type A into an object of type B by means of conversion functions. Every function declared as 'static B valueOf(A)', 'static B toB(A)', 'B A.toB()' and constructors of the form 'B(A)' are considered as conversion functions. If more than one conversion from type A to type B using those conversion functions is possible, the conversion is ambiguous and results in an error.- Parameters:
expr- source expressiontype- target typescope- current scopepos- location to use for error reportsmsg- message key to use for error reportsboxOnly- only check for autoboxing/unboxing, no further autoconversions- Returns:
- auto-converted expression, or
nullif no such conversion is possible andmsgisnull
-
createModel
-
allowsAmbiguousMembers
Description copied from interface:Members.ResolutionDefines if ambiguous members are allowed. If so, ambiguities between members do not cause an exception be thrown in; the first member is returned.invalid reference
Members#find(Resolution)- Specified by:
allowsAmbiguousMembersin interfaceMembers.Resolution- Parameters:
first- the first member of a set of ambiguous members- Returns:
trueiff ambiguous members are allowed andfirstshall be returned as the result of resolution
-
isApplicable
Description copied from interface:Members.ResolutionChecks whether a membermis applicable. The quality of applicability is stored inapplOutby this method.- Specified by:
isApplicablein interfaceMembers.Resolution- Parameters:
m- a memberappl- the quality of applicability is stored here by this methodscope- scope in which the member is accessed- Returns:
trueiffmis applicable
-
getArgumentTypes
Description copied from interface:Members.ResolutionReturns the argument types which are used inMembers.Resolution.isApplicable(Member, Members.Applicability, Scope)to determine the applicability. This method is only invoked to generate an error message in case no applicable member was found.- Specified by:
getArgumentTypesin interfaceMembers.Resolution- Returns:
- argument types
-
isLessThan
public boolean isLessThan(Member m1, Members.Applicability a1, Member m2, Members.Applicability a2, Scope scope) Description copied from interface:Members.ResolutionChecks whether an applicable memberm1is less specific than another applicable memberm2. The applicablities are the same instances which have been passed before toMembers.Resolution.isApplicable(Member, Members.Applicability, Scope).- Specified by:
isLessThanin interfaceMembers.Resolution- Parameters:
m1- a membera1-m1's applicability as determined byMembers.Resolution.isApplicable(Member, Members.Applicability, Scope)m2- another membera2-m2's applicability as determined byMembers.Resolution.isApplicable(Member, Members.Applicability, Scope)scope- scope in which the member is accessed- Returns:
trueiffm1is less specific thanm2
-
compileFieldExpression
public Expression compileFieldExpression(Field field, Expression expr, Scope scope, antlr.collections.AST pos) -
compileInstance
-
finish
-
checkOperatorFunction
public static void checkOperatorFunction(antlr.collections.AST params, antlr.collections.AST mods, antlr.collections.AST id, int symbol, RecognitionExceptionList exceptionList) -
getDefaultPackageName
Return the package name to use as default. The default package (in java) is "". That package is available from all other classes in the default package. For .rgg files to be available without package name (i.e. import Model.*) they need to be in the default java package. But for exporting the project as usable library, it easier if these classes get added to a defined package.
-