mirror of https://github.com/tbklang/tlang.git
Added quick fix for gotcha
This commit is contained in:
parent
7e05c1cbdb
commit
00920ad43b
|
@ -134,7 +134,15 @@ public final class StructuralOrganizer
|
||||||
*/
|
*/
|
||||||
if(clazz.getModifierType() != InitScope.STATIC)
|
if(clazz.getModifierType() != InitScope.STATIC)
|
||||||
{
|
{
|
||||||
Parser.expect("Cannot use a class type that is of a class that is non-static");
|
/**
|
||||||
|
* All module-level classes are static (even though not marked as such)
|
||||||
|
*
|
||||||
|
* TODO: Add this into the parser code to seth this
|
||||||
|
*/
|
||||||
|
if(clazz.parentOf() != tc.getModule())
|
||||||
|
{
|
||||||
|
Parser.expect("Cannot use a class type that is of a class that is non-static");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue