Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 1 addition & 3 deletions Phase1/Samples/1.fl
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,4 @@ def main()
a << b;
push(a, c);
puts(a);
end


end
6 changes: 6 additions & 0 deletions Phase1Template/.idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions Phase1Template/.idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions Phase1Template/.idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

44 changes: 44 additions & 0 deletions Phase1Template/.idea/workspace.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions Phase1Template/Phase1Template.iml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/untitled/gen" isTestSource="false" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
24 changes: 18 additions & 6 deletions Phase1Template/untitled/gen/main/grammer/FunctionCraft.interp

Large diffs are not rendered by default.

108 changes: 60 additions & 48 deletions Phase1Template/untitled/gen/main/grammer/FunctionCraft.tokens
Original file line number Diff line number Diff line change
Expand Up @@ -23,40 +23,46 @@ MULT=22
DIVIDE=23
EQUAL=24
NOT_EQUAL=25
IS_NOT=26
IS=27
LESS_EQUAL_THAN=26
GREATER_EQUAL_THAN=27
GREATER_THAN=28
LESS_THAN=29
AND=30
OR=31
NOT=32
INCREMENT=33
DECREMENT=34
SEPARATOR=35
APPEND=36
TRUE=37
FALSE=38
BREAK=39
NEXT=40
ARROW=41
ASSIGN=42
LPAR=43
RPAR=44
LBRACK=45
RBRACK=46
LBRACE=47
RBRACE=48
COMMA=49
DOT=50
DOUBLEDOT=51
COLON=52
SEMICOLLON=53
INT_VALUE=54
FLOAT_VALUE=55
IDENTIFIER=56
STRING_VALUE=57
COMMENT=58
WS=59
PATTERN_MATCHING_SEPARATOR=35
SEPARATOR=36
APPEND=37
TRUE=38
FALSE=39
BREAK=40
NEXT=41
ARROW=42
PLUS_ASSIGN=43
MINUS_ASSIGN=44
MULT_ASSIGN=45
DIVIDE_ASSIGN=46
MOD_ASSIGN=47
ASSIGN=48
LPAR=49
RPAR=50
LBRACK=51
RBRACK=52
LBRACE=53
RBRACE=54
COMMA=55
DOT=56
DOUBLEDOT=57
COLON=58
SEMICOLLON=59
INT_VALUE=60
FLOAT_VALUE=61
IDENTIFIER=62
STRING_VALUE=63
COMMENT=64
WS=65
'def'=1
'end'=2
'main'=3
Expand All @@ -82,31 +88,37 @@ WS=59
'/'=23
'=='=24
'!='=25
'is not'=26
'is'=27
'<='=26
'>='=27
'>'=28
'<'=29
'&&'=30
'||'=31
'!'=32
'++'=33
'--'=34
'|'=35
'<<'=36
'true'=37
'false'=38
'break'=39
'next'=40
'->'=41
'='=42
'('=43
')'=44
'['=45
']'=46
'{'=47
'}'=48
','=49
'.'=50
'..'=51
':'=52
';'=53
' |'=35
'|'=36
'<<'=37
'true'=38
'false'=39
'break'=40
'next'=41
'->'=42
'+='=43
'-='=44
'*='=45
'/='=46
'%='=47
'='=48
'('=49
')'=50
'['=51
']'=52
'{'=53
'}'=54
','=55
'.'=56
'..'=57
':'=58
';'=59
Original file line number Diff line number Diff line change
Expand Up @@ -305,61 +305,61 @@ public class FunctionCraftBaseListener implements FunctionCraftListener {
*
* <p>The default implementation does nothing.</p>
*/
@Override public void enterRelationalExpression(FunctionCraftParser.RelationalExpressionContext ctx) { }
@Override public void enterEqaulityExpression(FunctionCraftParser.EqaulityExpressionContext ctx) { }
/**
* {@inheritDoc}
*
* <p>The default implementation does nothing.</p>
*/
@Override public void exitRelationalExpression(FunctionCraftParser.RelationalExpressionContext ctx) { }
@Override public void exitEqaulityExpression(FunctionCraftParser.EqaulityExpressionContext ctx) { }
/**
* {@inheritDoc}
*
* <p>The default implementation does nothing.</p>
*/
@Override public void enterAdditiveExpression(FunctionCraftParser.AdditiveExpressionContext ctx) { }
@Override public void enterRelationalExpression(FunctionCraftParser.RelationalExpressionContext ctx) { }
/**
* {@inheritDoc}
*
* <p>The default implementation does nothing.</p>
*/
@Override public void exitAdditiveExpression(FunctionCraftParser.AdditiveExpressionContext ctx) { }
@Override public void exitRelationalExpression(FunctionCraftParser.RelationalExpressionContext ctx) { }
/**
* {@inheritDoc}
*
* <p>The default implementation does nothing.</p>
*/
@Override public void enterMultiplicativeExpression(FunctionCraftParser.MultiplicativeExpressionContext ctx) { }
@Override public void enterAdditiveExpression(FunctionCraftParser.AdditiveExpressionContext ctx) { }
/**
* {@inheritDoc}
*
* <p>The default implementation does nothing.</p>
*/
@Override public void exitMultiplicativeExpression(FunctionCraftParser.MultiplicativeExpressionContext ctx) { }
@Override public void exitAdditiveExpression(FunctionCraftParser.AdditiveExpressionContext ctx) { }
/**
* {@inheritDoc}
*
* <p>The default implementation does nothing.</p>
*/
@Override public void enterPreUnaryExpression(FunctionCraftParser.PreUnaryExpressionContext ctx) { }
@Override public void enterMultiplicativeExpression(FunctionCraftParser.MultiplicativeExpressionContext ctx) { }
/**
* {@inheritDoc}
*
* <p>The default implementation does nothing.</p>
*/
@Override public void exitPreUnaryExpression(FunctionCraftParser.PreUnaryExpressionContext ctx) { }
@Override public void exitMultiplicativeExpression(FunctionCraftParser.MultiplicativeExpressionContext ctx) { }
/**
* {@inheritDoc}
*
* <p>The default implementation does nothing.</p>
*/
@Override public void enterAppendExpression(FunctionCraftParser.AppendExpressionContext ctx) { }
@Override public void enterPreUnaryExpression(FunctionCraftParser.PreUnaryExpressionContext ctx) { }
/**
* {@inheritDoc}
*
* <p>The default implementation does nothing.</p>
*/
@Override public void exitAppendExpression(FunctionCraftParser.AppendExpressionContext ctx) { }
@Override public void exitPreUnaryExpression(FunctionCraftParser.PreUnaryExpressionContext ctx) { }
/**
* {@inheritDoc}
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -186,35 +186,35 @@ public class FunctionCraftBaseVisitor<T> extends AbstractParseTreeVisitor<T> imp
* <p>The default implementation returns the result of calling
* {@link #visitChildren} on {@code ctx}.</p>
*/
@Override public T visitRelationalExpression(FunctionCraftParser.RelationalExpressionContext ctx) { return visitChildren(ctx); }
@Override public T visitEqaulityExpression(FunctionCraftParser.EqaulityExpressionContext ctx) { return visitChildren(ctx); }
/**
* {@inheritDoc}
*
* <p>The default implementation returns the result of calling
* {@link #visitChildren} on {@code ctx}.</p>
*/
@Override public T visitAdditiveExpression(FunctionCraftParser.AdditiveExpressionContext ctx) { return visitChildren(ctx); }
@Override public T visitRelationalExpression(FunctionCraftParser.RelationalExpressionContext ctx) { return visitChildren(ctx); }
/**
* {@inheritDoc}
*
* <p>The default implementation returns the result of calling
* {@link #visitChildren} on {@code ctx}.</p>
*/
@Override public T visitMultiplicativeExpression(FunctionCraftParser.MultiplicativeExpressionContext ctx) { return visitChildren(ctx); }
@Override public T visitAdditiveExpression(FunctionCraftParser.AdditiveExpressionContext ctx) { return visitChildren(ctx); }
/**
* {@inheritDoc}
*
* <p>The default implementation returns the result of calling
* {@link #visitChildren} on {@code ctx}.</p>
*/
@Override public T visitPreUnaryExpression(FunctionCraftParser.PreUnaryExpressionContext ctx) { return visitChildren(ctx); }
@Override public T visitMultiplicativeExpression(FunctionCraftParser.MultiplicativeExpressionContext ctx) { return visitChildren(ctx); }
/**
* {@inheritDoc}
*
* <p>The default implementation returns the result of calling
* {@link #visitChildren} on {@code ctx}.</p>
*/
@Override public T visitAppendExpression(FunctionCraftParser.AppendExpressionContext ctx) { return visitChildren(ctx); }
@Override public T visitPreUnaryExpression(FunctionCraftParser.PreUnaryExpressionContext ctx) { return visitChildren(ctx); }
/**
* {@inheritDoc}
*
Expand Down
Loading