broken shitty code

This commit is contained in:
Clemens-Dautermann 2020-08-23 00:54:58 +02:00
parent e6b20b5aa9
commit 5ec5c64775
28 changed files with 322 additions and 72 deletions

View file

@ -27,6 +27,7 @@
<e p="WrongTypeException.cs" t="Include" />
</e>
<e p="Nodes" t="Include">
<e p="BinaryOperatorNode.cs" t="Include" />
<e p="ConstantNode.cs" t="Include" />
<e p="FunctionNode.cs" t="Include" />
<e p="Node.cs" t="Include" />

View file

@ -20,13 +20,34 @@
</component>
<component name="ChangeListManager">
<list default="true" id="a54bb6de-191c-4bd1-91ab-3953adfc5dfb" name="Default Changelist" comment="">
<change afterPath="$PROJECT_DIR$/DevFunctions.cs" afterDir="false" />
<change afterPath="$PROJECT_DIR$/Generator/NotSpecifiedException.cs" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../test" afterDir="false" />
<change afterPath="$PROJECT_DIR$/Parser/Nodes/BinaryOperatorNode.cs" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/invalid/malformed_paren.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/invalid/missing_first_op.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/invalid/missing_second_op.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/invalid/no_semicolon.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/add.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/associativity.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/associativity_2.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/div.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/div_neg.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/mult.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/parens.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/precedence.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/sub.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/sub_neg.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/unop_add.c" afterDir="false" />
<change afterPath="$PROJECT_DIR$/../stage_3/valid/unop_parens.c" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/.idea.Compiler/.idea/contentModel.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/.idea.Compiler/.idea/contentModel.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/.idea.Compiler/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/.idea.Compiler/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Compiler.cs" beforeDir="false" afterPath="$PROJECT_DIR$/Compiler.cs" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Generator/Generator.cs" beforeDir="false" afterPath="$PROJECT_DIR$/Generator/Generator.cs" afterDir="false" />
<change beforePath="$PROJECT_DIR$/DevFunctions.cs" beforeDir="false" afterPath="$PROJECT_DIR$/DevFunctions.cs" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Lexer/Lexer.cs" beforeDir="false" afterPath="$PROJECT_DIR$/Lexer/Lexer.cs" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Lexer/TokenType.cs" beforeDir="false" afterPath="$PROJECT_DIR$/Lexer/TokenType.cs" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Parser/Nodes/ConstantNode.cs" beforeDir="false" afterPath="$PROJECT_DIR$/Parser/Nodes/ConstantNode.cs" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Parser/Nodes/NodeType.cs" beforeDir="false" afterPath="$PROJECT_DIR$/Parser/Nodes/NodeType.cs" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Parser/Nodes/OperatorType.cs" beforeDir="false" afterPath="$PROJECT_DIR$/Parser/Nodes/OperatorType.cs" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Parser/Parser.cs" beforeDir="false" afterPath="$PROJECT_DIR$/Parser/Parser.cs" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../grammar" beforeDir="false" afterPath="$PROJECT_DIR$/../grammar" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../test" beforeDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
@ -46,6 +67,8 @@
<component name="HighlightingSettingsPerFile">
<setting file="file://$PROJECT_DIR$/Compiler.cs" root0="FORCE_HIGHLIGHTING" />
<setting file="file://$APPLICATION_CONFIG_DIR$/resharper-host/DecompilerCache/decompiler/714153FB-3DE5-4537-8A59-8AE8F7F7655E/44/126d3750/String.cs" root0="SKIP_HIGHLIGHTING" />
<setting file="mock:///Dummy.cs" root0="SKIP_HIGHLIGHTING" />
<setting file="mock:///Dummy.cs" root0="SKIP_HIGHLIGHTING" />
<setting file="file://$PROJECT_DIR$/Lexer/Lexer.cs" root0="FORCE_HIGHLIGHTING" />
<setting file="file://$PROJECT_DIR$/Lexer/Token.cs" root0="FORCE_HIGHLIGHTING" />
<setting file="file://$APPLICATION_CONFIG_DIR$/resharper-host/DecompilerCache/decompiler/EEDBFCB1-C56E-4F7A-8B60-B8DD27E0DC7D/86/71102cca/Enumerable.cs" root0="SKIP_HIGHLIGHTING" />
@ -96,20 +119,21 @@
<option value="$PROJECT_DIR$/Parser/Exceptions/UnexpectedTokenException.cs" />
<option value="$PROJECT_DIR$/t.tt" />
<option value="$PROJECT_DIR$/Parser/Nodes/ReturnNode.cs" />
<option value="$PROJECT_DIR$/Lexer/TokenType.cs" />
<option value="$PROJECT_DIR$/Lexer/Lexer.cs" />
<option value="$PROJECT_DIR$/../grammar" />
<option value="$PROJECT_DIR$/Parser/Nodes/OperatorTypes.cs" />
<option value="$PROJECT_DIR$/Parser/Nodes/OperatorType.cs" />
<option value="$PROJECT_DIR$/Parser/Nodes/NodeType.cs" />
<option value="$PROJECT_DIR$/Parser/Nodes/UnaryOperatorNode.cs" />
<option value="$PROJECT_DIR$/Parser/Nodes/ConstantNode.cs" />
<option value="$PROJECT_DIR$/Parser/Parser.cs" />
<option value="$PROJECT_DIR$/Compiler.cs" />
<option value="$PROJECT_DIR$/Generator/NotSpecifiedException.cs" />
<option value="$PROJECT_DIR$/../test.s" />
<option value="$PROJECT_DIR$/DevFunctions.cs" />
<option value="$PROJECT_DIR$/Generator/Generator.cs" />
<option value="$PROJECT_DIR$/Lexer/TokenType.cs" />
<option value="$PROJECT_DIR$/Lexer/Lexer.cs" />
<option value="$PROJECT_DIR$/Parser/Nodes/NodeType.cs" />
<option value="$PROJECT_DIR$/Parser/Nodes/BinaryOperatorNode.cs" />
<option value="$PROJECT_DIR$/Parser/Nodes/OperatorType.cs" />
<option value="$PROJECT_DIR$/../grammar" />
<option value="$PROJECT_DIR$/DevFunctions.cs" />
<option value="$PROJECT_DIR$/Parser/Nodes/ConstantNode.cs" />
<option value="$PROJECT_DIR$/Parser/Parser.cs" />
</list>
</option>
</component>
@ -124,13 +148,13 @@
<component name="PropertiesComponent">
<property name="ASKED_ADD_EXTERNAL_FILES" value="true" />
<property name="ASKED_SHARE_PROJECT_CONFIGURATION_FILES" value="true" />
<property name="DebuggerViewTab_PTCS_FirstProportionKey" value="0.56953055" />
<property name="DebuggerViewTab_PTCS_LastProportionKey" value="0.4880425" />
<property name="DebuggerViewTab_PTCS_FirstProportionKey" value="0.5697674" />
<property name="DebuggerViewTab_PTCS_LastProportionKey" value="0.4883721" />
<property name="RunOnceActivity.OpenProjectViewOnStart" value="true" />
<property name="RunOnceActivity.ShowReadmeOnStart" value="true" />
<property name="SHARE_PROJECT_CONFIGURATION_FILES" value="true" />
<property name="WebServerToolWindowFactoryState" value="false" />
<property name="XThreadsFramesViewSplitterKey" value="0.2616179" />
<property name="XThreadsFramesViewSplitterKey" value="0.44757032" />
<property name="last_opened_file_path" value="$PROJECT_DIR$/.." />
<property name="settings.editor.selected.configurable" value="preferences.pluginManager" />
</component>
@ -173,7 +197,9 @@
<workItem from="1597695400525" duration="4873000" />
<workItem from="1597863017034" duration="9651000" />
<workItem from="1597932102881" duration="4296000" />
<workItem from="1597952695048" duration="9189000" />
<workItem from="1597952695048" duration="9233000" />
<workItem from="1598037838306" duration="329000" />
<workItem from="1598123734996" duration="12557000" />
</task>
<servers />
</component>
@ -231,70 +257,70 @@
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.-1.right/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955238557" />
<state width="908" height="298" key="GridCell.Tab.0.bottom" timestamp="1597956915348">
<state width="1292" height="330" key="GridCell.Tab.0.bottom" timestamp="1598136287234">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="908" height="298" key="GridCell.Tab.0.bottom/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597956915348" />
<state width="908" height="298" key="GridCell.Tab.0.center" timestamp="1597956915348">
<state width="1292" height="330" key="GridCell.Tab.0.bottom/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287234" />
<state width="1292" height="330" key="GridCell.Tab.0.center" timestamp="1598136287234">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="908" height="298" key="GridCell.Tab.0.center/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597956915348" />
<state width="908" height="298" key="GridCell.Tab.0.left" timestamp="1597956915348">
<state width="1292" height="330" key="GridCell.Tab.0.center/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287234" />
<state width="1292" height="330" key="GridCell.Tab.0.left" timestamp="1598136287234">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="908" height="298" key="GridCell.Tab.0.left/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597956915348" />
<state width="908" height="298" key="GridCell.Tab.0.right" timestamp="1597956915348">
<state width="1292" height="330" key="GridCell.Tab.0.left/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287234" />
<state width="1292" height="330" key="GridCell.Tab.0.right" timestamp="1598136287234">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="908" height="298" key="GridCell.Tab.0.right/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597956915348" />
<state width="1868" height="383" key="GridCell.Tab.1.bottom" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.0.right/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287234" />
<state width="1292" height="330" key="GridCell.Tab.1.bottom" timestamp="1598136287234">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.1.bottom/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1868" height="383" key="GridCell.Tab.1.center" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.1.bottom/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287234" />
<state width="1292" height="330" key="GridCell.Tab.1.center" timestamp="1598136287234">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.1.center/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1868" height="383" key="GridCell.Tab.1.left" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.1.center/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287234" />
<state width="1292" height="330" key="GridCell.Tab.1.left" timestamp="1598136287234">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.1.left/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1868" height="383" key="GridCell.Tab.1.right" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.1.left/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287234" />
<state width="1292" height="330" key="GridCell.Tab.1.right" timestamp="1598136287234">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.1.right/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1868" height="383" key="GridCell.Tab.2.bottom" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.1.right/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287234" />
<state width="1292" height="330" key="GridCell.Tab.2.bottom" timestamp="1598136287235">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.2.bottom/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1868" height="383" key="GridCell.Tab.2.center" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.2.bottom/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287235" />
<state width="1292" height="330" key="GridCell.Tab.2.center" timestamp="1598136287235">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.2.center/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1868" height="383" key="GridCell.Tab.2.left" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.2.center/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287235" />
<state width="1292" height="330" key="GridCell.Tab.2.left" timestamp="1598136287234">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.2.left/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1868" height="383" key="GridCell.Tab.2.right" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.2.left/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287234" />
<state width="1292" height="330" key="GridCell.Tab.2.right" timestamp="1598136287235">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.2.right/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1868" height="383" key="GridCell.Tab.3.bottom" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.2.right/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287235" />
<state width="1292" height="330" key="GridCell.Tab.3.bottom" timestamp="1598136287235">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.3.bottom/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1868" height="383" key="GridCell.Tab.3.center" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.3.bottom/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287235" />
<state width="1292" height="330" key="GridCell.Tab.3.center" timestamp="1598136287235">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.3.center/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1868" height="383" key="GridCell.Tab.3.left" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.3.center/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287235" />
<state width="1292" height="330" key="GridCell.Tab.3.left" timestamp="1598136287235">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.3.left/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1868" height="383" key="GridCell.Tab.3.right" timestamp="1597955439042">
<state width="1292" height="330" key="GridCell.Tab.3.left/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287235" />
<state width="1292" height="330" key="GridCell.Tab.3.right" timestamp="1598136287235">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state width="1868" height="383" key="GridCell.Tab.3.right/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597955439042" />
<state width="1292" height="330" key="GridCell.Tab.3.right/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598136287235" />
<state width="1868" height="383" key="GridCell.Tab.4.bottom" timestamp="1597955234640">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
@ -315,10 +341,10 @@
<screen x="0" y="0" width="1920" height="1080" />
</state>
<state x="631" y="291" width="806" height="524" key="Rider.ProjectTemplateDialog.Size/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597872082099" />
<state x="2321" y="-64" width="709" height="485" key="RiderGenerateDialog" timestamp="1597956793201">
<state x="2315" y="-106" width="709" height="485" key="RiderGenerateDialog" timestamp="1598127182892">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state x="2321" y="-64" width="709" height="485" key="RiderGenerateDialog/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597956793201" />
<state x="2315" y="-106" width="709" height="485" key="RiderGenerateDialog/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598127182892" />
<state x="2525" y="135" width="1031" height="724" key="SettingsEditor" timestamp="1597932248704">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
@ -335,10 +361,10 @@
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state x="2182" y="199" width="432" height="650" key="com.intellij.openapi.editor.actions.MultiplePasteAction$ClipboardContentChooser/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597510086756" />
<state x="0" y="557" width="1920" height="523" key="dock-window-1" timestamp="1597960555163">
<screen x="0" y="0" width="1920" height="1080" />
<state x="3264" y="0" width="576" height="1080" key="dock-window-1" timestamp="1598127152431">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
<state x="0" y="557" width="1920" height="523" key="dock-window-1/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597960555163" />
<state x="3264" y="0" width="576" height="1080" key="dock-window-1/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1598127152431" />
<state x="3200" y="0" width="640" height="1080" key="dock-window-2" timestamp="1597959520918">
<screen x="1920" y="0" width="1920" height="1080" />
</state>
@ -352,4 +378,36 @@
</state>
<state x="2543" y="239" width="672" height="678" key="search.everywhere.popup/1920.0.1920.1080/0.0.1920.1080@1920.0.1920.1080" timestamp="1597698616567" />
</component>
<component name="XDebuggerManager">
<breakpoint-manager>
<breakpoints>
<line-breakpoint enabled="true" type="DotNet Breakpoints">
<url>file://$PROJECT_DIR$/DevFunctions.cs</url>
<line>86</line>
<properties documentPath="$PROJECT_DIR$/DevFunctions.cs" initialLine="82">
<startOffsets>
<option value="2557" />
</startOffsets>
<endOffsets>
<option value="2606" />
</endOffsets>
</properties>
<option name="timeStamp" value="4" />
</line-breakpoint>
<line-breakpoint enabled="true" type="DotNet Breakpoints">
<url>file://$PROJECT_DIR$/Parser/Parser.cs</url>
<line>107</line>
<properties documentPath="$PROJECT_DIR$/Parser/Parser.cs" initialLine="107">
<startOffsets>
<option value="3498" />
</startOffsets>
<endOffsets>
<option value="3524" />
</endOffsets>
</properties>
<option name="timeStamp" value="12" />
</line-breakpoint>
</breakpoints>
</breakpoint-manager>
</component>
</project>