mirror of
https://github.com/mudabbir-ahmad/UNI-PROG3-CW2-DYOPL.git
synced 2026-10-08 04:00:20 +00:00
Refactor RobotLangVisitorUser to remove unnecessary imports and clean up code
This commit is contained in:
1 parent
ea6d32b726
commit
3fc4eac47b
2 files changed
+2
-9
No files matched your search
@@ -1,8 +1,4 @@
|
|||||||
from antlr4 import *
|
from RobotLangVisitor import RobotLangVisitor
|
||||||
if "." in __name__:
|
|
||||||
from .RobotLangParser import RobotLangParser
|
|
||||||
else:
|
|
||||||
from RobotLangParser import RobotLangParser
|
|
||||||
|
|
||||||
class RobotLangVisitorUser(RobotLangVisitor):
|
class RobotLangVisitorUser(RobotLangVisitor):
|
||||||
def __init__(self, student_id="2320390"):
|
def __init__(self, student_id="2320390"):
|
||||||
@@ -37,7 +33,4 @@ class RobotLangVisitorUser(RobotLangVisitor):
|
|||||||
# Visit all statements inside the repeat block
|
# Visit all statements inside the repeat block
|
||||||
for stat_ctx in ctx.stat():
|
for stat_ctx in ctx.stat():
|
||||||
self.visit(stat_ctx)
|
self.visit(stat_ctx)
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
|
||||||
del RobotLangParser
|
|
||||||
BIN
Binary file not shown.
Reference in new issue
Block a user