Yukang
31d10393da
remove unnecessary return
2013-08-18 20:21:48 +08:00
Carson McDonald
7d41835ded
Fix return block argument error
2013-08-14 16:56:42 -04:00
Yukihiro "Matz" Matsumoto
b225e4cc82
redesign mruby/data.h API; use DATA_PTR() for raw data pointer, DATA_GET_PTR() to type safe retrieval (TypeError will be raised), DATA_CHECK_GET_PTR() to get nil if type mismatched
2013-08-15 01:33:36 +09:00
Yukihiro "Matz" Matsumoto
babc8d0086
implement Class.new in C again
2013-08-15 00:35:41 +09:00
Yukihiro "Matz" Matsumoto
f8454e53ba
check d->type before accessing d->type->dfree; #1474 #858
2013-08-14 16:51:50 +09:00
Yukihiro "Matz" Matsumoto
0dfda0c970
longjmp too far when exception raised from C function called from mrb_funcall()
2013-08-14 16:30:52 +09:00
Yukihiro "Matz" Matsumoto
81903eb9bf
Merge pull request #1472 from JackDanger/jackdanger/add-line-numbers-to-irb
...
Adding line numbers to the output of mirb.
2013-08-13 17:48:10 -07:00
Yukihiro "Matz" Matsumoto
8fa02a2cc7
Merge pull request #1470 from carsonmcdonald/morefixfor1467
...
Tests and another fix for issue #1467
2013-08-13 17:44:22 -07:00
Jack Danger Canty
2bf4952284
Adding line numbers to the output of mirb.
...
Before:
> "hi"
hi
> d
(mirb):1: undefined method 'd' for main (NoMethodError)
> d
(mirb):1: undefined method 'd' for main (NoMethodError)
> "hi"
hi
> "#{'}"
line 1: unterminated string meets end of file
After
> "hi"
hi
> d
(mirb):2: undefined method 'd' for main (NoMethodError)
> d
(mirb):3: undefined method 'd' for main (NoMethodError)
> "hi"
hi
> "#{'}"
line 5: unterminated string meets end of file
2013-08-13 09:53:52 -07:00
Carson McDonald
7a2e0d6cf5
This check and class change is redundant because it is done in class.c#mrb_include_module
2013-08-13 11:38:27 -04:00
Carson McDonald
5a6a557f72
Remove debug printf
2013-08-13 11:30:51 -04:00
Yukihiro "Matz" Matsumoto
b822c0b35e
ci->target_class should point to ICLASS, not MODULE; close #1467
2013-08-14 00:13:32 +09:00
Yukihiro "Matz" Matsumoto
6b015ec775
define Class#new in ruby to call #initialize
2013-08-13 16:55:06 +09:00
fleuria
6dcf2ffb08
fix #1459
...
gen_vmassignment() missed a pop() in a conditional branch, but we have
to keep each conditional branch 's stack depth the same all the time
when it left execution.
2013-08-12 14:18:09 +08:00
Yukihiro "Matz" Matsumoto
4f1fe9a3ee
Merge pull request #1458 from suzukaze/fix-iso-no-in-string-class
...
I fix ISO no in String class in comparison with ISO_IEC_30170_2012(E)
2013-08-11 18:28:10 -07:00
Jun Hiroe
d4b2d0a912
I fix ISO No in String class in comparison with ISO_IEC_30170_2012(E)-Charactor_PDF_document.pdf
2013-08-11 21:15:01 +09:00
Yukihiro "Matz" Matsumoto
f6fa07235b
Merge pull request #1450 from Fleurer/cleanup-warninigs
...
clean up the warnings when GC_PROFILE is set
2013-08-09 07:59:09 -07:00
Yukihiro "Matz" Matsumoto
53f750dbed
def statement and define_method now return symbol a la Ruby2.1
2013-08-09 22:25:45 +09:00
fleuria
b3b4f2dbdb
clean up the warnings when GC_PROFILE is on
2013-08-09 17:38:09 +08:00
Yukihiro "Matz" Matsumoto
3d3ca985b0
remove duplicated incremental_gc_until() in generational GC; #1449
2013-08-09 18:11:16 +09:00
fleuria
7e7943322b
add comments for major GC
2013-08-09 15:43:06 +08:00
Cremno
08911d1c82
parse.y: fixed bison 3.0 warning
...
YACC src/parse.y -> build/host/src/y.tab.c
src/parse.y:936.1-12: warning: deprecated directive, use ‘%pure-parser’
[-Wdeprecated]
%pure_parser
2013-08-09 03:30:08 +02:00
Yukihiro "Matz" Matsumoto
30f86069de
finish half-baked GC cycle before starting full GC; #1447
2013-08-08 22:08:12 +09:00
Yukihiro "Matz" Matsumoto
1e87bf6d2f
allow turning off GC generational mode by default by MRB_GC_TURN_OFF_GENERATIONAL; #1447
2013-08-08 21:42:20 +09:00
Yukihiro "Matz" Matsumoto
3b2b760ed3
Merge pull request #1445 from cremno/no_strcpy_and_strcat
...
don't use str{cpy,cat} in mruby and mrbc
2013-08-07 16:23:31 -07:00
Cremno
123c88759c
class.c and numeric.c: fixed MSVC warnings
2013-08-07 20:48:23 +02:00
Cremno
29381bc819
parse.y: don't use strcat
2013-08-07 20:35:38 +02:00
Yukihiro "Matz" Matsumoto
62303a80cf
Merge pull request #1444 from Fleurer/issue1442
...
fix #1442
2013-08-07 05:33:32 -07:00
fleuria
22ac62a4f1
fix #1442
...
in the marking root phase, we only marked the root context, but leaving
the current context unmarked. when we execute a fiber, the current
context would be changed and trigger this issue.
2013-08-07 19:42:56 +08:00
Yukihiro "Matz" Matsumoto
a61def802e
return statement should terminate execution of a method defined by define_method
2013-08-07 17:45:24 +09:00
Yukihiro "Matz" Matsumoto
40e6cdcb5c
rename mrb_value_p() to mrb_ptr() since _p means predicate in mruby source
2013-08-07 17:39:28 +09:00
Yuichi Nishiwaki
8854ecb629
revert one of the API changes: MRB_SET_VALUE_P no longer used
2013-08-04 00:40:41 -07:00
Yuichi Nishiwaki
8dc2fa3bc8
add read barrier to value.p
...
API changes:
- value.p must be accessed via mrb_value_p macro
- value.p must be mutated via MRB_SET_VALUE_P macro
2013-08-03 14:03:44 -07:00
Carson McDonald
5bd60f4662
End loop if nextc is -1
2013-08-02 17:08:55 -04:00
Yukihiro "Matz" Matsumoto
a32fdf3e5d
Merge pull request #1426 from Fleurer/clear-all-old
...
add comments for clear_all_old()
2013-08-01 07:01:26 -07:00
fleuria
107906e3cb
revise the comment in mrb_full_gc()
...
the old comment "clean all the black object as old" looks confusing,
it looks like "transform black object to old object", but indeed black
is old,
2013-08-01 17:50:13 +08:00
fleuria
c1469a57a2
add comment for clear_all_old()
2013-08-01 17:30:57 +08:00
Yukihiro "Matz" Matsumoto
429e69243c
remove unused inspect_range
2013-08-01 18:29:55 +09:00
Yukihiro "Matz" Matsumoto
7f282429b0
ci->target_class should be updated as well; #1418
2013-08-01 11:56:20 +09:00
Yukihiro "Matz" Matsumoto
c550a0f834
move mrb_gc_arena_restore() after cipop(); a bug found by Kilo Kawai
2013-07-31 22:24:10 +09:00
Yukihiro "Matz" Matsumoto
029613bc55
stop storing target_class info for C defined methods
2013-07-31 00:31:37 +09:00
Yukihiro "Matz" Matsumoto
326396a6e3
remove unused mrb_proc_new_with_target()
2013-07-31 00:16:55 +09:00
Yukihiro "Matz" Matsumoto
294ed98011
Merge branch 'master' of github.com:mruby/mruby
2013-07-30 01:33:14 +09:00
Yukihiro "Matz" Matsumoto
dbd36128ad
forget to re-initialize target_class for top-level eval; close #1418
2013-07-30 01:33:02 +09:00
Yukihiro "Matz" Matsumoto
4229b41c68
Merge pull request #1421 from carsonmcdonald/fixfor1419
...
Remove pop that was done when not a return val
2013-07-29 09:16:29 -07:00
Carson McDonald
ff40793fc7
Remove pop that was done when not a return val
2013-07-28 13:15:22 -04:00
Yukihiro "Matz" Matsumoto
e488393cbb
Merge branch 'master' of github.com:mruby/mruby
2013-07-27 02:53:02 +09:00
Yukihiro "Matz" Matsumoto
63e5a3cfb1
refactor out longjmp() to a function
2013-07-25 14:54:17 +09:00
fleuria
620e323d15
replace assert with mrb_assert
2013-07-25 03:00:03 +08:00
fleuria
bbbe996e0d
replace gc_assert with mrb_assert
2013-07-25 02:55:51 +08:00