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
36efd018
Unverified
Commit
36efd018
authored
Nov 03, 2021
by
Yukihiro "Matz" Matsumoto
Committed by
GitHub
Nov 03, 2021
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #5565 from dearblue/class.new
Improved `Class#new` method
parents
59b7846a
33792c2a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
src/class.c
src/class.c
+5
-5
No files found.
src/class.c
View file @
36efd018
...
...
@@ -2840,17 +2840,17 @@ static const mrb_code new_iseq[] = {
OP_LOADSELF
,
4
,
// OP_LOADSELF R4
OP_SEND
,
4
,
0
,
0
,
// OP_SEND R4 :allocate n=0
OP_MOVE
,
0
,
4
,
// OP_MOVE R0 R4
OP_MOVE
,
5
,
1
,
// OP_MOVE R5 R1 (*
)
OP_MOVE
,
6
,
2
,
// OP_MOVE R6
R2 (**)
OP_MOVE
,
7
,
3
,
// OP_MOVE R7 R3
OP_S
ENDB
,
4
,
1
,
255
,
// OP_SENDB R4
:initialize n=*|nk=*
OP_MOVE
,
4
,
3
,
// OP_MOVE R4 R3 (&
)
OP_MOVE
,
3
,
2
,
// OP_MOVE R3
R2 (**)
OP_MOVE
,
2
,
1
,
// OP_MOVE R2 R1 (*)
OP_S
SENDB
,
1
,
1
,
255
,
// OP_SSENDB R1
:initialize n=*|nk=*
OP_RETURN
,
0
// OP_RETURN R0
};
MRB_PRESYM_DEFINE_VAR_AND_INITER
(
new_syms
,
2
,
MRB_SYM
(
allocate
),
MRB_SYM
(
initialize
))
static
const
mrb_irep
new_irep
=
{
3
,
6
,
0
,
MRB_IREP_STATIC
,
4
,
5
,
0
,
MRB_IREP_STATIC
,
new_iseq
,
NULL
,
new_syms
,
NULL
,
NULL
,
NULL
,
sizeof
(
new_iseq
),
0
,
2
,
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