Skip to content

Commit d966947

Browse files
committed
Exclusively handle classes in their bodies.
1 parent 6663c92 commit d966947

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/main/java/org/luapp/language/handlers/StatementHandler.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,16 +44,17 @@ public void onEnterContext(ParserRuleContext enterContext) {
4444

4545
for (ParseTree child : enterContext.children) {
4646
if(child instanceof luappParser.ClassbodyContext){
47-
this
47+
this.listenerManager.GetInstangeByTarget(luappParser.RULE_classbody).handleEnterContext(enterContext);
48+
return;
4849
}
4950
}
5051

5152
if(this.isParentClass(enterContext)) {
5253
System.out.println("Parent is the class!");
53-
//return;
54+
return;
5455
}
5556
if(this.isChildIgnored(enterContext)){
56-
//return;
57+
return;
5758
}
5859
//System.out.println("NewLine:" + this.getLuaPP().getRawFromContext(enterContext));
5960
this.addToLuaPPResult(this.getLuaPP().getRawFromContext(enterContext));

0 commit comments

Comments
 (0)