Yukihiro "Matz" Matsumoto
afca99a40b
Remove implicit conversion using to_int method.
...
The ISO standard does not include implicit type conversion using
`to_int`. This implicit conversion often causes vulnerability.
There will be no more attacks like #4120 .
In addition, we have added internal convenience method `__to_int` which
does type check and conversion (from floats).
2018-11-19 11:28:51 +09:00
Yukihiro "Matz" Matsumoto
1d781da8a6
Should not include float.h here.
2017-08-11 13:52:01 +09:00
Yukihiro "Matz" Matsumoto
bc1259de3b
add explicit casts
2017-01-02 17:48:44 +09:00
Yukihiro "Matz" Matsumoto
79a621dd73
Check before retrieving struct RRange pointer; fix #3320
...
range->edges may be NULL for example when #initialize_copy removed.
2016-12-03 12:30:01 +09:00
Tomasz Dąbrowski
72ed7eebc3
Fixed Range.size to use proper floating point tolerance
2016-11-24 12:50:49 +01:00
Yukihiro "Matz" Matsumoto
a70104798e
remove unnecessary ".!"; ref #3261
2016-11-22 16:55:18 +09:00
ksss
682237be6e
Reimplements Range#first
...
Range#first shouldn't call `Range#to_a` on infinity range.
2016-11-21 16:55:49 +09:00
ksss
22390aa1c8
Use mrb_float instead of double
2016-11-19 23:25:08 +09:00
ksss
a2fbd80a47
Fix Range#size results
2016-11-19 23:25:07 +09:00
Yukihiro "Matz" Matsumoto
5c405dea3d
include changed from by quotes ("") to by brackets (<>); close #3032
2015-11-27 17:48:23 +09:00
Jun Hiroe
4e4929bc72
Rename extended xxxx class or module to xxxx class or module extension
2015-06-28 11:18:52 +09:00
Jun Hiroe
c69d1201e1
Fix typo; Replace extensional with extended
2015-06-28 00:05:58 +09:00
Yukihiro "Matz" Matsumoto
91a025b1e6
reimplement Range#size using double with fixing corner cases; ref #2293
2014-05-19 18:04:27 +09:00
Jun Hiroe
4b3ff090ab
Add Range#size
2014-05-19 16:17:10 +09:00
Yukihiro "Matz" Matsumoto
7c82b9e1bf
use mrb_get_args("i")
2014-03-21 23:36:03 +09:00
take_cheeze
c73f8d4def
move summary of mrbgems in default gembox to its spec
2014-03-17 00:34:24 +09:00
cremno
09bb30870b
tiny word boxing optimization
2014-01-02 06:36:29 +01:00
Daniel Bovensiepen
d10763190e
Improve test of mruby-range-ext GEM
2013-08-04 22:42:06 +08:00
Tomoyuki Sahara
116f75a8ce
"spec.author" is better for single-author gems.
...
"spec.author=" expects a String represents a single author.
"spec.authors=" expects an Array which is a list of multiple authors.
http://guides.rubygems.org/specification-reference/
2013-07-23 10:09:24 +09:00
Jun Hiroe
8e42868600
Repalace int with mrb_bool because a return value is boolean.
2013-07-15 23:17:12 +09:00
Yukihiro "Matz" Matsumoto
30d580ecbc
rename every ARGS_XXX to MRB_ARGS_XXX; ref #1206
2013-04-25 09:47:36 +09:00
h2so5
1d10912076
Add mruby-range-ext
2013-04-14 13:59:46 +09:00