Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
LSH
lsh
Commits
10bc3df7
Commit
10bc3df7
authored
Mar 10, 1999
by
Niels Möller
Browse files
* src/command.c (do_call_simple_command): COMMAND_CALL method for
any command_simple instances. Rev: src/command.c:1.4
parent
e03e7b34
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/command.c
View file @
10bc3df7
...
@@ -58,25 +58,35 @@ make_apply(struct command *f, struct command_continuation *c)
...
@@ -58,25 +58,35 @@ make_apply(struct command *f, struct command_continuation *c)
return
&
res
->
super
.
super
;
return
&
res
->
super
.
super
;
}
}
int
do_call_simple_command
(
struct
command
*
c
,
struct
lsh_object
*
arg
,
struct
command_continuation
*
c
)
{
CAST_SUBTYPE
(
command_simple
,
self
,
c
);
return
COMMAND_RETURN
(
c
,
COMMAND_SIMPLE
(
self
,
arg
));
}
/* Combinators */
/* Combinators */
/* Ix == x */
/* Ix == x */
#if 0
static int do_command_I(struct command *ignored UNUSED,
static int do_command_I(struct command *ignored UNUSED,
struct lsh_object *arg,
struct lsh_object *arg,
struct command_continuation *c)
struct command_continuation *c)
{
{
return COMMAND_RETURN(c, arg);
return COMMAND_RETURN(c, arg);
}
}
#endif
static
struct
lsh_object
*
do_
simple
_I
(
struct
command_simple
*
ignored
UNUSED
,
static
struct
lsh_object
*
do_
command
_I
(
struct
command_simple
*
ignored
UNUSED
,
struct
lsh_object
*
arg
)
struct
lsh_object
*
arg
)
{
{
return
arg
;
return
arg
;
}
}
struct
command_simple
command_I
=
struct
command_simple
command_I
=
STATIC_COMMAND_SIMPLE
(
do_command_I
);
{
{
STATIC_HEADER
,
do_command_I
}
do_simple_I
};
/* ((S f) g)x == (f x)(g x) */
/* ((S f) g)x == (f x)(g x) */
...
...
Write
Preview
Supports
Markdown
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