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
cc5f40b2
Commit
cc5f40b2
authored
Nov 06, 2016
by
Felix Jones
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mrb_class_under_defined docs renamed parent and child to outer and inner
parent
8d6aa065
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
include/mruby.h
include/mruby.h
+7
-7
No files found.
include/mruby.h
View file @
cc5f40b2
...
...
@@ -567,18 +567,18 @@ MRB_API mrb_bool mrb_class_defined(mrb_state *mrb, const char *name);
MRB_API
struct
RClass
*
mrb_class_get
(
mrb_state
*
mrb
,
const
char
*
name
);
/**
* Returns an mrb_bool. True if
child class was defined, and false if the child
class was not defined.
* Returns an mrb_bool. True if
inner class was defined, and false if the inner
class was not defined.
*
* Example:
* void
* mrb_example_gem_init(mrb_state* mrb) {
* struct RClass *example_
parent, *example_child
;
* struct RClass *example_
outer, *example_inner
;
* mrb_bool cd;
*
* example_
parent = mrb_define_module(mrb, "ExampleParent
");
* example_
outer = mrb_define_module(mrb, "ExampleOuter
");
*
* example_
child = mrb_define_class(mrb, "ExampleChild
", mrb->object_class);
* cd = mrb_class_under_defined(mrb, example_
parent, "ExampleChild
");
* example_
inner = mrb_define_class_under(mrb, example_outer, "ExampleInner
", mrb->object_class);
* cd = mrb_class_under_defined(mrb, example_
outer, "ExampleInner
");
*
* // If mrb_class_under_defined returns 1 then puts "True"
* // If mrb_class_under_defined returns 0 then puts "False"
...
...
@@ -591,8 +591,8 @@ MRB_API struct RClass * mrb_class_get(mrb_state *mrb, const char *name);
* }
*
* @param [mrb_state*] mrb The current mruby state.
* @param [struct RClass *] outer The name of the
parent
class.
* @param [const char *] name A string representing the name of the
child
class.
* @param [struct RClass *] outer The name of the
outer
class.
* @param [const char *] name A string representing the name of the
inner
class.
* @return [mrb_bool] A boolean value.
*/
MRB_API
mrb_bool
mrb_class_under_defined
(
mrb_state
*
mrb
,
struct
RClass
*
outer
,
const
char
*
name
);
...
...
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