Commit Graph

33 Commits

Author SHA1 Message Date
Danila Fedorin 8c5306051e Add a toString for UnaryPrefixNode 2017-07-28 14:57:11 -07:00
Danila Fedorin 556a72f946 Change the constructor for NumberNode 2017-07-28 14:47:34 -07:00
Danila Fedorin 0c07695991 Merge branch 'unary' 2017-07-28 13:28:59 -07:00
Danila Fedorin 2ba6e22fcb Rename OpNode to BinaryInfixNode. 2017-07-28 11:15:36 -07:00
Danila Fedorin 5228773b5e Implement unary operators. 2017-07-28 11:14:45 -07:00
Danila Fedorin 42393ca6a6 Add operator types. 2017-07-28 10:26:25 -07:00
Danila Fedorin a881640bf6 Make the decimal matching optional. 2017-07-28 09:52:14 -07:00
Danila Fedorin 2cc4bd14ce Switch all uses of *List, *Map to just List and Map. 2017-07-27 18:19:12 -07:00
Danila Fedorin 65772c8d57 Fix function argument order. 2017-07-27 16:52:16 -07:00
Danila Fedorin bbbb2e855e Fix typo. 2017-07-27 16:37:54 -07:00
Danila Fedorin 8a29019852 Add ignoring whitespace and fix function precedence. 2017-07-27 16:36:13 -07:00
Danila Fedorin b0ae3f90fc Add sanitization to TreeBuilder. 2017-07-27 15:26:02 -07:00
Danila Fedorin f7da896fc0 Fix several bugs and register operations as operations. 2017-07-27 14:15:45 -07:00
Danila Fedorin 2ca23fd427 Implement correct plugin loading and registration. 2017-07-27 14:06:57 -07:00
Danila Fedorin f931b9f322 Move parsing code into TreeBuilder, change lexing and parsing algorithms 2017-07-27 13:25:57 -07:00
Danila Fedorin 189f8c6e15 Move OperatorAssociativity into the function class. 2017-07-27 09:33:01 -07:00
Danila Fedorin e8595510b8 Remove the caret operator as it is not implemented. 2017-07-27 09:23:07 -07:00
Danila Fedorin b09c9c3cb2 Remove unnecessary getType() calls. 2017-07-27 09:22:24 -07:00
Danila Fedorin cf95ed7dc0 Add comments to NumberReducer and FunctionNode. 2017-07-26 19:16:10 -07:00
Danila Fedorin c8146954c3 Implement reducing functions. 2017-07-26 18:44:30 -07:00
Danila Fedorin d18e27bdb4 Implement parsing functions. 2017-07-26 18:44:17 -07:00
Danila Fedorin c4eb70999b Add correct handling of failed reduces to both OpNode and Window. 2017-07-26 18:41:21 -07:00
Danila Fedorin d7caf1cdc7 Implement toString in child nodes of TreeNode. 2017-07-26 17:26:55 -07:00
Danila Fedorin 8754871556 Make some operator-related fields protected in TreeNode.
This should allow for the implementation of toString in child nodes.
2017-07-26 17:26:42 -07:00
Danila Fedorin 50baf80433 Add a new constructor to the UI, and move strings into constants. 2017-07-26 13:33:24 -07:00
Danila Fedorin f7d4d01bc8 Correctly handle invalid strings. 2017-07-26 13:25:12 -07:00
Danila Fedorin ec030607bf Remove unnecessary pattern. 2017-07-26 13:25:01 -07:00
Danila Fedorin 798ee6f7c3 Implement the ability to reduce a tree to a single variable of a type. 2017-07-26 10:58:27 -07:00
Danila Fedorin 08999350f4 Add more comments. 2017-07-26 10:10:37 -07:00
Danila Fedorin 38255b1219 Merge tree construction feature into master. 2017-07-25 14:28:12 -07:00
Danila Fedorin e4e9e2ce21 Implement parsing a postfix expression into a tree. 2017-07-25 14:21:00 -07:00
Danila Fedorin 3684673362 Implement Shunting Yard. 2017-07-25 13:53:38 -07:00
Danila Fedorin 1dcd6beb1c Implement two enums for conversion between strings and tokens. 2017-07-25 11:08:03 -07:00