Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mruby
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
mruby
Commits
60df7778
Commit
60df7778
authored
Mar 14, 2013
by
kano4
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add break to default case in switch statement
parent
08a0c9f3
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
6 additions
and
0 deletions
+6
-0
src/array.c
src/array.c
+1
-0
src/class.c
src/class.c
+1
-0
src/codegen.c
src/codegen.c
+1
-0
src/kernel.c
src/kernel.c
+2
-0
src/symbol.c
src/symbol.c
+1
-0
No files found.
src/array.c
View file @
60df7778
...
...
@@ -702,6 +702,7 @@ mrb_ary_aget(mrb_state *mrb, mrb_value self)
default:
mrb_raise
(
mrb
,
E_ARGUMENT_ERROR
,
"wrong number of arguments"
);
break
;
}
return
mrb_nil_value
();
/* dummy to avoid warning : not reach here */
...
...
src/class.c
View file @
60df7778
...
...
@@ -408,6 +408,7 @@ mrb_get_args(mrb_state *mrb, const char *format, ...)
if
(
argc
<=
i
&&
!
opt
)
{
mrb_raise
(
mrb
,
E_ARGUMENT_ERROR
,
"wrong number of arguments"
);
}
break
;
}
switch
(
c
)
{
...
...
src/codegen.c
View file @
60df7778
...
...
@@ -379,6 +379,7 @@ dispatch(codegen_scope *s, int pc)
fprintf
(
stderr
,
"bug: dispatch on non JMP op
\n
"
);
#endif
scope_error
(
s
);
break
;
}
s
->
iseq
[
pc
]
=
MKOP_AsBx
(
c
,
GETARG_A
(
i
),
diff
);
}
...
...
src/kernel.c
View file @
60df7778
...
...
@@ -518,6 +518,7 @@ mrb_obj_instance_eval(mrb_state *mrb, mrb_value self)
default:
cv
=
mrb_singleton_class
(
mrb
,
self
);
c
=
mrb_class_ptr
(
cv
);
break
;
}
return
mrb_yield_internal
(
mrb
,
b
,
0
,
0
,
self
,
c
);
}
...
...
@@ -931,6 +932,7 @@ mrb_f_raise(mrb_state *mrb, mrb_value self)
exc
=
mrb_make_exception
(
mrb
,
argc
,
a
);
mrb_obj_iv_set
(
mrb
,
mrb_obj_ptr
(
exc
),
mrb_intern
(
mrb
,
"lastpc"
),
mrb_voidp_value
(
mrb
->
ci
->
pc
));
mrb_exc_raise
(
mrb
,
exc
);
break
;
}
return
mrb_nil_value
();
/* not reached */
}
...
...
src/symbol.c
View file @
60df7778
...
...
@@ -240,6 +240,7 @@ is_special_global_name(const char* m)
default:
if
(
!
ISDIGIT
(
*
m
))
return
FALSE
;
do
++
m
;
while
(
ISDIGIT
(
*
m
));
break
;
}
return
!*
m
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment