summaryrefslogtreecommitdiffhomepage
path: root/src/parse.y
AgeCommit message (Collapse)Author
2015-06-01Compile mruby compiler as mrbgem.take_cheeze
Compiler codes is moved to "mruby-compiler". Executable `mrbc` is moved to "mruby-bin-mrbc".
2015-05-28fix capture group index bugcremno
atoi() is used to convert the index to an int but the behavior is undefined if the value can't be represented. > $9999999999 00007 NODE_SCOPE: 00007 NODE_BEGIN: 00007 NODE_NTH_REF: $2147483647 irep 00630580 nregs=2 nlocals=1 pools=0 syms=1 reps=0 file: (mirb) 7 000 OP_GETGLOBAL R1 :$2147483647 7 001 OP_STOP Call strtoul() instead as its behavior in such cases is defined and add a simple range check. Alternatively NODE_NTH_REF's cdr could be changed from int to mrb_sym (like NODE_GVAR).
2015-05-25Move "src/mrb_throw.h" to "include/mruby/throw.h".take_cheeze
Related to #2760.
2015-05-23Add null check on lex_strterm in heredoc blockCarson McDonald
2015-05-22Add locals null checksCarson McDonald
2015-05-20there may be expecting here-doc when we see terminating characters; fix #2780Yukihiro "Matz" Matsumoto
2015-05-13remove unused token declarationscremno
2015-05-04define YYDEBUG macro conditionallycremno
The YYDEBUG macro enables parser debugging which unnecessarily increases the executable size (9 to 10 KB). Now it only will be defined when PARSER_DEBUG is too.
2015-04-30push cmdarg_stack in lambda body; fix [ruby-bug#11107]Yukihiro "Matz" Matsumoto
2015-04-30Merge pull request #2777 from cremno/fix-parser-locals-null-derefYukihiro "Matz" Matsumoto
parser: fix possible null dereferences
2015-04-28fix null dereference (ref: #2769)cremno
parser_state->locals might be a null pointer. Fixes (and other similiar invalid code): def a; Proc.new do def x==x end end
2015-04-28prevent accidental macro redefinition of strndup()cremno
2015-04-27parser_state->locals may be NULL on some error conditions; fix #2769Yukihiro "Matz" Matsumoto
2014-12-11mrb_parser_dump() did not work with block argumentsYukihiro "Matz" Matsumoto
2014-11-22should support recursive mlhs decomposition, e.g. (a,b),c = [1,2],3Yukihiro "Matz" Matsumoto
2014-10-28Merge pull request #2621 from suzukaze/fix-parse_stringYukihiro "Matz" Matsumoto
Replace int with mrb_bool in parse_string func
2014-10-28Replace int with mrb_bool in parse_string funcJun Hiroe
2014-10-28Replace int with mrb_bool in local_var_p funcJun Hiroe
2014-10-27Refactor yylex funcJun Hiroe
2014-10-27Refactor mrbc_context_new funcJun Hiroe
2014-09-08fixed wandering filename problemYukihiro "Matz" Matsumoto
2014-09-05add some MRB_API to function prototypesYukihiro "Matz" Matsumoto
2014-09-04rename a local variable current_node -> nodetype; ref #2583Yukihiro "Matz" Matsumoto
2014-09-03get rid of shadowing variablescremno
Mostly by renaming the shadowing variable. If a shadowing variable was deleted, the shadowed one can be used instead.
2014-08-29allow no_optimize esp. for debuggerYukihiro "Matz" Matsumoto
2014-08-29Fix mismatches for MRB_API declarations.Tatsuhiko Kubo
2014-08-29adjust node lineno of muiti line statementsYukihiro "Matz" Matsumoto
2014-08-29print lineno of dumping nodeYukihiro "Matz" Matsumoto
2014-08-26printf: cast variables to the expected typecremno
%x expects unsigned int and %p expects void * GCC emits a diagnostic about %p/void* in pedantic mode: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=26542
2014-08-25Remove spaces in end-of-line.Tatsuhiko Kubo
2014-08-20Use specified macro(NULL) instead of magic-number.Tatsuhiko Kubo
2014-06-25Not create local variables in scope_newksss
2014-06-25Merge branch 'master' of github.com:mruby/mrubyYukihiro "Matz" Matsumoto
2014-06-25Merge pull request #2333 from yui-knk/fix/dumpYukihiro "Matz" Matsumoto
Fix to not print unnecessary comma.
2014-06-25revert #2344 because of #2395Yukihiro "Matz" Matsumoto
2014-06-21clear local variables for the first execution of mrb_context_run(); close #2405Yukihiro "Matz" Matsumoto
2014-06-14Merge pull request #2344 from yui-knk/fix-localsYukihiro "Matz" Matsumoto
Change to always use locals->car->car.
2014-06-13Fixed dead assignment in 'parser.y' reported by 'clang-analyzer'Jose Narvaez
2014-06-13Fixed dead assignment in 'parser.y' reported by 'clang-analyzer'Jose Narvaez
2014-06-13Fixed dead assignment in 'parser.y' reported by 'clang-analyzer'Jose Narvaez
2014-06-13Fixed dead assignment in 'parse.y' reported by 'clang-analyzer'Jose Narvaez
2014-06-08do not ignore negative characters (e.g. EOF and partial EOF); fix #2361 fix ↵Yukihiro "Matz" Matsumoto
#2369
2014-06-08revert #2368 due to #2369Yukihiro "Matz" Matsumoto
2014-06-06Treat partial hook success '\n' to fix #2361 .take_cheeze
Now it will parse the #2361 code as: ``` module A end module B end ``` instead of ``` module A end module B end ```
2014-06-05use uppercase US-ASCII ctype macroscremno
2014-06-05don't (re-)define `ascii_isspace` and `isascii`cremno
`ISSPACE` and `ISASCII` can be used instead.
2014-06-05`ISSPACE` evaluates its argument multiple timescremno
2014-06-03Fix indent.yui-knk
2014-06-03Remove space.yui-knk
2014-06-02Change to always use locals->car->car.yui-knk
When p->locals->car is not NULL and p->locals->car->car is NULL, local_add_f dose not append sym to p->locals->car->car. This commit change to append sym to p->locals->car->car. This will close #2333.