mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Remove unnecessary check for size_t < 0
size_t can never be negative since it is an unsigned integer according to standard. Removed to silence warning. Signed-off-by: Patrick Hogan <pbhogan@gmail.com>
This commit is contained in:
@@ -35,9 +35,6 @@ mrb_ary_new_capa(mrb_state *mrb, size_t capa)
|
||||
{
|
||||
struct RArray *a;
|
||||
|
||||
if (capa < 0) {
|
||||
mrb_raise(mrb, E_ARGUMENT_ERROR, "negative ary size (or size too big)");
|
||||
}
|
||||
#ifdef LONG_MAX
|
||||
if (capa > ARY_MAX_SIZE) {
|
||||
mrb_raise(mrb, E_ARGUMENT_ERROR, "ary size too big");
|
||||
|
||||
Reference in New Issue
Block a user