Commit graph

73 commits

Author SHA1 Message Date
Wolfgang (Blub) Bumiller
104e9bce92 don't add the general 'parse error' message if an error has already been printed 2012-08-14 11:54:27 +02:00
Wolfgang (Blub) Bumiller
579ac3dd5d Working towards a saner error-output system, adding -Werror 2012-08-14 11:34:07 +02:00
Wolfgang (Blub) Bumiller
c08966a2a4 remove now unused files 2012-08-14 10:57:09 +02:00
Wolfgang (Blub) Bumiller
69d9afbc69 while, for 2012-08-13 17:10:13 +02:00
Wolfgang (Blub) Bumiller
1c4a11f6fb factored out 'if' parsing code into a function, added 'while' parsing, and errors for more unsupported operators 2012-08-13 16:45:35 +02:00
Wolfgang (Blub) Bumiller
5ca3fed36a Even more operators 2012-08-13 15:33:32 +02:00
Wolfgang (Blub) Bumiller
d8890fda9e More operations 2012-08-13 15:24:55 +02:00
Wolfgang (Blub) Bumiller
5390b2d7c2 nicer error messages, bitand and bitor for floats allowed 2012-08-13 15:13:43 +02:00
Wolfgang (Blub) Bumiller
9f151e82df Check types on + and - operations 2012-08-13 15:09:27 +02:00
Wolfgang (Blub) Bumiller
c7cca404dc after a closing paren another operator has to be expected again 2012-08-12 20:21:21 +02:00
Wolfgang (Blub) Bumiller
fb8a9b3ccf some debug outputs which can be activated via a define, fixing a bug where the shunting yard tries to apply operators when there are none left 2012-08-12 20:13:14 +02:00
Wolfgang (Blub) Bumiller
6806fd1e86 it's a member of entity, not of a field... 2012-08-12 19:29:18 +02:00
Wolfgang (Blub) Bumiller
6409bf455f -std=gmqcc way to handle fields by 'namespace' 2012-08-12 19:24:08 +02:00
Wolfgang (Blub) Bumiller
ae73332832 without -std=gmqcc fields are accessible anywhere where globals are 2012-08-12 19:02:52 +02:00
Wolfgang (Blub) Bumiller
437988c5b4 don't rewind local variables too far 2012-08-12 18:58:46 +02:00
Wolfgang (Blub) Bumiller
5c0ac35d4c tempcomitting parser changes for fields 2012-08-11 15:40:03 +02:00
Wolfgang (Blub) Bumiller
ce082551d8 handling if/else, shunting yard now leaves unmatched closing paren-tokens on the parser for this purpose 2012-08-11 11:17:46 +02:00
Wolfgang (Blub) Bumiller
3e4f490a59 Handling blocks and inner blocks 2012-08-11 10:35:10 +02:00
Wolfgang (Blub) Bumiller
d3d2e00b64 let's be less insane with function naming and prepare parsing for control structures 2012-08-11 10:30:54 +02:00
Wolfgang (Blub) Bumiller
167b432622 creating vector's _xyz globals now, accessing them 2012-08-10 22:59:47 +02:00
Wolfgang Bumiller
71d79d99d3 parser_init,compile,finish,cleanup - used in main 2012-07-28 21:21:41 +02:00
Wolfgang Bumiller
342836c6df adapting to change in master: ast_store takes an ast_expression 2012-07-28 18:17:29 +02:00
Wolfgang Bumiller
ae12583ada Adding more cleanup; checking whether or not a return has the right type 2012-07-28 16:06:55 +02:00
Wolfgang Bumiller
75812d486a Handling output file, writing output file 2012-07-27 18:22:39 +02:00
Wolfgang Bumiller
79753d05bd Handling vector constants now too 2012-07-27 16:20:53 +02:00
Wolfgang Bumiller
b88e25ed81 Handling string-immediates 2012-07-27 16:10:43 +02:00
Wolfgang Bumiller
0a5e5c07e5 Adapting to changes of where parameters are stored in master 2012-07-27 15:26:48 +02:00
Wolfgang Bumiller
6379d39bb7 Starting some typechecking. Function parameters must be part of ast_expression_common, they're part of the type, not ast_value... 2012-07-27 15:07:25 +02:00
Wolfgang Bumiller
65f4f03aa5 Handling calls correctly now 2012-07-27 15:02:39 +02:00
Wolfgang Bumiller
c79bc784a3 Parsing function calls 2012-07-27 14:40:43 +02:00
Wolfgang Bumiller
3618d071ff fixing comma operator 2012-07-27 13:42:02 +02:00
Wolfgang Bumiller
e8b63575b2 keeping blocks around 2012-07-27 13:28:57 +02:00
Wolfgang Bumiller
6b85f3d370 factoring out the closing-paren handling code since it'll be used recursively 2012-07-27 13:07:16 +02:00
Wolfgang Bumiller
623046dda8 the comma is now in the operator list 2012-07-27 12:53:15 +02:00
Wolfgang Bumiller
f03bffc3ee opening paren and comma to the operator stack for function calls 2012-07-27 12:35:14 +02:00
Wolfgang Bumiller
b81b5d8c4d Removing some debug output 2012-07-27 12:28:14 +02:00
Wolfgang Bumiller
b70fd7e238 handle parameters in parser_find_local 2012-07-27 12:25:46 +02:00
Wolfgang Bumiller
a99972d7dd Parse named parameters of functions 2012-07-26 23:33:19 +02:00
Wolfgang Bumiller
5d766f60b2 parse ahead into the return expression as expected 2012-07-26 23:26:34 +02:00
Wolfgang Bumiller
e1c4600260 Listen to the warning instead... 2012-07-26 23:25:33 +02:00
Wolfgang Bumiller
b08de6ee5f Shutup a warning... 2012-07-26 23:24:36 +02:00
Wolfgang Bumiller
a0d78e985c handling return 2012-07-26 23:22:51 +02:00
Wolfgang Bumiller
dcb815a65f Handling parenthesis in expressions 2012-07-22 11:17:01 +02:00
Wolfgang Bumiller
21a2679efb add locals to their ast_block, can create stores now 2012-07-20 21:32:51 +02:00
Wolfgang Bumiller
071fd32040 Handling some operands, added type_name array 2012-07-20 21:19:30 +02:00
Wolfgang Bumiller
f78ed233c0 parser_sy_pop, has to pop operators and operands and push the result 2012-07-20 15:20:07 +02:00
Wolfgang Bumiller
9f54ea6643 working on operator translation 2012-07-20 15:03:11 +02:00
Wolfgang Bumiller
7185366ee5 handling of operations 2012-07-20 15:02:18 +02:00
Wolfgang Bumiller
5d6767f337 Starting expression parsing 2012-07-20 14:45:23 +02:00
Wolfgang Bumiller
e8563442a1 keeping float immediates/constants in parser's imm_float vector 2012-07-20 14:34:45 +02:00