summaryrefslogtreecommitdiffhomepage
path: root/src/codegen.c
AgeCommit message (Collapse)Author
2014-03-05fix off-by-one error in attrsymcubicdaiya
The allocation size for null-terminated character is lacking. In actual, it is no problem in most case because codegen_palloc allocates more a memory size than required size.
2014-03-03rescue clause should understand splats; close #1786Yukihiro "Matz" Matsumoto
2014-03-01support c++ exceptiontake_cheeze
2014-03-01use C style comments instead of C++ style commentscubicdaiya
According to CONTRIBUTING.md, Don't use C++ style comments /* This is the prefered comment style */ Use C++ style comments only for temporary comment e.g. commenting out some code lines.
2014-02-09Merge pull request #1674 from cremno/mrb_bool-FALSE-TRUEYukihiro "Matz" Matsumoto
use mrb_bool, FALSE and TRUE more
2014-02-04better codedump formatYukihiro "Matz" Matsumoto
2014-02-01fix NODE_SPLAT codegenh2so5
2014-01-31use mrb_bool, FALSE and TRUE morecremno
It doesn't matter to me if one is using FALSE/TRUE instead of 1/0 but I prefer a type (alias) which emphasizes boolean vars to int. I changed 1/0 to FALSE/TRUE anyway.
2014-01-31clean up external symbolscremno
remove unused and unneeded: - sysexit_status - type (a global variable) add mrb_ prefix to: - codedump_all - class_instance_method_list - parser_dump make various functions static, incl.: - yyparse - make_exception
2014-01-04should splat and iterate elements when "*ary" speficied in the case-when ↵Yukihiro "Matz" Matsumoto
clause; close #1627
2014-01-02Merge pull request #1634 from cremno/use-mrb_fixnum_pYukihiro "Matz" Matsumoto
tiny word boxing optimization
2014-01-02tiny word boxing optimizationcremno
2014-01-02codegen.c: remove superfluous returncremno
2013-12-27return-value of mrb_run is invalid in top-level-scopecubicdaiya
The return-value of mrb_run in top-level-scope should be the evaluated value at last.
2013-12-26adjust register position for return value; fix #1620Yukihiro "Matz" Matsumoto
2013-12-26revert fix in #1620Yukihiro "Matz" Matsumoto
2013-12-25Fix return when value expectedCarson McDonald
2013-12-25Merge branch 'master' of github.com:mruby/mrubyYukihiro "Matz" Matsumoto
2013-12-24fix #1617h2so5
2013-12-24class/module body to honor whether value is required or not; reduce a few ↵Yukihiro "Matz" Matsumoto
instructions for normal cases
2013-12-19fix codegen bug in NODE_CASEh2so5
2013-12-03avoid top-level pool release at codegen_error() and fixed some memory leaksYukihiro "Matz" Matsumoto
2013-12-03should not access scope after releasing memory poolYukihiro "Matz" Matsumoto
2013-12-02Merge pull request #1601 from carsonmcdonald/srcaptosizetYukihiro "Matz" Matsumoto
Change scapa and rcapa to size_t, use scapa.
2013-12-02Change scapa and rcapa to size_t, use scapa.Carson McDonald
2013-12-01add mrb_intern_lit for creating symbol from string literaltake_cheeze
2013-11-29rename mrb_intern2() to mrb_intern(); huge API incompatibility; close #1513Yukihiro "Matz" Matsumoto
2013-11-27float objects in pool are objects when MRB_WORD_BOXING is setYukihiro "Matz" Matsumoto
2013-11-26Fix build error for MRB_WORD_BOXINGkyab
2013-11-20rename API mrb_str_dup_static() -> mrb_str_pool()Yukihiro "Matz" Matsumoto
2013-11-20resolve conflictYukihiro "Matz" Matsumoto
2013-11-19irep->pool struct pool -> mrb_valueMiura Hideki
2013-11-18codegen_malloc/realloc: static + simple mem alloccremno
- there's no reason for both to have external linkage - use simple versions of memory allocation functions which are returning NULL instead of longjmp-ing, so codegen_error will be called to cleanup.
2013-11-15enum mrb_vtype varies on compile time configuration, namely MRB_NAN_BOXINGYukihiro "Matz" Matsumoto
2013-11-13Changed a variable declaration to top of blockbggd
2013-11-09protect returning irep (in proc) from GCYukihiro "Matz" Matsumoto
2013-11-07type check before pool scanYukihiro "Matz" Matsumoto
2013-11-07create Proc object before releasing memory poolYukihiro "Matz" Matsumoto
2013-11-07irep->pool not to be GCedYukihiro "Matz" Matsumoto
2013-11-07modified to use irep->reps to reference child ireps. preparation forYukihiro "Matz" Matsumoto
removing irep array from mrb_state. note that instructions OP_LAMBDA, OP_EXEC and OP_EPUSH are incompatible, and dumped mrb format has changed.
2013-11-02remove scope->idxYukihiro "Matz" Matsumoto
2013-11-02codedump() to take irep structureYukihiro "Matz" Matsumoto
2013-11-02change return value from mrb_generate_code()Yukihiro "Matz" Matsumoto
2013-10-25fix #1544fleuria
We have already reserved that register in codegen()'s case NODE_DEF, but what we care about is actually the previous register. So what we need is get that register by cursp() after pop(), then recover the reservation by push().
2013-10-01fix #1519fleuria
the 128th element in an array literal would trigger a corner case on splat mode checking, in which mruby will splat an that value into its parent array. the issue was masked by the fact of ary_concat() also accept non-array value: 1.9.3p286 :002> a = 1 1.9.3p286 :003> [*a] => [1] the expected behaviour should be OP_ARYPUSH the 128th element, instead of splat it by OP_ARYCAT.
2013-09-20remove unreferenced local variables caused by mrb_assert()Yukihiro "Matz" Matsumoto
2013-09-20rename node->filename to node->filename_indexYukihiro "Matz" Matsumoto
2013-09-20refactor genop_peep(); ref #1505Yukihiro "Matz" Matsumoto
2013-09-18Fix self value in a block is changed with return value for Fixnum, nil, ↵Keita Obo
instance variable. Fix #1504
2013-09-18Fixed self value in a block is changed with return valueKeita Obo
fix #1504