Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
pike
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
pikelang
pike
Commits
5207bb2a
Commit
5207bb2a
authored
28 years ago
by
Fredrik Hübinette (Hubbe)
Browse files
Options
Downloads
Patches
Plain Diff
new function: low_clone()
Rev: src/object.c:1.13 Rev: src/object.h:1.8
parent
db3e1385
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/object.c
+9
-5
9 additions, 5 deletions
src/object.c
src/object.h
+1
-0
1 addition, 0 deletions
src/object.h
with
10 additions
and
5 deletions
src/object.c
+
9
−
5
View file @
5207bb2a
...
@@ -4,7 +4,7 @@
...
@@ -4,7 +4,7 @@
||| See the files COPYING and DISCLAIMER for more information.
||| See the files COPYING and DISCLAIMER for more information.
\*/
\*/
#include
"global.h"
#include
"global.h"
RCSID
(
"$Id: object.c,v 1.1
2
1997/0
1/2
7 01:
22:56
hubbe Exp $"
);
RCSID
(
"$Id: object.c,v 1.1
3
1997/0
2/0
7 01:
33:03
hubbe Exp $"
);
#include
"object.h"
#include
"object.h"
#include
"dynamic_buffer.h"
#include
"dynamic_buffer.h"
#include
"interpret.h"
#include
"interpret.h"
...
@@ -33,7 +33,7 @@ void setup_fake_object()
...
@@ -33,7 +33,7 @@ void setup_fake_object()
fake_object
.
refs
=
0xffffff
;
fake_object
.
refs
=
0xffffff
;
}
}
static
struct
object
*
low_clone
(
struct
program
*
p
)
struct
object
*
low_clone
(
struct
program
*
p
)
{
{
int
e
;
int
e
;
struct
object
*
o
;
struct
object
*
o
;
...
@@ -103,14 +103,18 @@ static struct object *low_clone(struct program *p)
...
@@ -103,14 +103,18 @@ static struct object *low_clone(struct program *p)
return
o
;
return
o
;
}
}
st
ruct
object
*
clone
(
struct
program
*
p
,
int
args
)
st
atic
void
init_object
(
struct
object
*
o
,
int
args
)
{
{
struct
object
*
o
=
low_clone
(
p
);
apply_lfun
(
o
,
LFUN___INIT
,
0
);
apply_lfun
(
o
,
LFUN___INIT
,
0
);
pop_stack
();
pop_stack
();
apply_lfun
(
o
,
LFUN_CREATE
,
args
);
apply_lfun
(
o
,
LFUN_CREATE
,
args
);
pop_stack
();
pop_stack
();
}
struct
object
*
clone
(
struct
program
*
p
,
int
args
)
{
struct
object
*
o
=
low_clone
(
p
);
init_object
(
o
,
args
);
return
o
;
return
o
;
}
}
...
...
This diff is collapsed.
Click to expand it.
src/object.h
+
1
−
0
View file @
5207bb2a
...
@@ -38,6 +38,7 @@ extern struct program *master_program;
...
@@ -38,6 +38,7 @@ extern struct program *master_program;
/* Prototypes begin here */
/* Prototypes begin here */
void
setup_fake_object
();
void
setup_fake_object
();
struct
object
*
low_clone
(
struct
program
*
p
);
struct
object
*
clone
(
struct
program
*
p
,
int
args
);
struct
object
*
clone
(
struct
program
*
p
,
int
args
);
struct
object
*
get_master
();
struct
object
*
get_master
();
struct
object
*
master
();
struct
object
*
master
();
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment