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
444e4b79
Commit
444e4b79
authored
Aug 19, 2014
by
Yukihiro "Matz" Matsumoto
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2538 from kkkkkt/refactor-method
refactor mruby method(fix indent. remove temporary value etc)
parents
98a95530
2f1d12c7
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
8 additions
and
14 deletions
+8
-14
src/array.c
src/array.c
+1
-1
src/codegen.c
src/codegen.c
+2
-2
src/kernel.c
src/kernel.c
+2
-3
src/load.c
src/load.c
+2
-4
src/object.c
src/object.c
+1
-4
No files found.
src/array.c
View file @
444e4b79
src/codegen.c
View file @
444e4b79
src/kernel.c
View file @
444e4b79
...
...
@@ -739,7 +739,6 @@ mrb_obj_methods(mrb_state *mrb, mrb_bool recur, mrb_value obj, mrb_method_flag_t
{
if
(
recur
)
return
mrb_class_instance_method_list
(
mrb
,
recur
,
mrb_class
(
mrb
,
obj
),
0
);
else
return
mrb_obj_singleton_methods
(
mrb
,
recur
,
obj
);
}
/* 15.3.1.3.31 */
...
...
src/load.c
View file @
444e4b79
...
...
@@ -337,7 +337,7 @@ read_debug_record(mrb_state *mrb, const uint8_t *start, mrb_irep* irep, size_t *
size_t
len
;
int
ret
;
ret
=
read_debug_record
(
mrb
,
bin
,
irep
->
reps
[
i
],
&
len
,
filenames
,
filenames_len
);
ret
=
read_debug_record
(
mrb
,
bin
,
irep
->
reps
[
i
],
&
len
,
filenames
,
filenames_len
);
if
(
ret
!=
MRB_DUMP_OK
)
return
ret
;
bin
+=
len
;
}
...
...
@@ -570,7 +570,6 @@ MRB_API mrb_value
mrb_load_irep_cxt
(
mrb_state
*
mrb
,
const
uint8_t
*
bin
,
mrbc_context
*
c
)
{
mrb_irep
*
irep
=
mrb_read_irep
(
mrb
,
bin
);
mrb_value
val
;
struct
RProc
*
proc
;
if
(
!
irep
)
{
...
...
@@ -580,8 +579,7 @@ mrb_load_irep_cxt(mrb_state *mrb, const uint8_t *bin, mrbc_context *c)
proc
=
mrb_proc_new
(
mrb
,
irep
);
mrb_irep_decref
(
mrb
,
irep
);
if
(
c
&&
c
->
no_exec
)
return
mrb_obj_value
(
proc
);
val
=
mrb_toplevel_run
(
mrb
,
proc
);
return
val
;
return
mrb_toplevel_run
(
mrb
,
proc
);
}
MRB_API
mrb_value
...
...
src/object.c
View file @
444e4b79
...
...
@@ -310,12 +310,9 @@ convert_type(mrb_state *mrb, mrb_value val, const char *tname, const char *metho
if
(
!
mrb_respond_to
(
mrb
,
val
,
m
))
{
if
(
raise
)
{
mrb_raisef
(
mrb
,
E_TYPE_ERROR
,
"can't convert %S into %S"
,
inspect_type
(
mrb
,
val
),
mrb_str_new_cstr
(
mrb
,
tname
));
return
mrb_nil_value
();
}
else
{
return
mrb_nil_value
();
}
}
return
mrb_funcall_argv
(
mrb
,
val
,
m
,
0
,
0
);
}
...
...
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