bshell: re-organise build into three separate components
bshell: the front-end binary bshell.runtime: contains the parser, compiler, and classes needed to run bshell scripts bshell.core: contains the builtin commandlets and aliases
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
#include "../syntax.h"
|
||||
|
||||
bool parse_expr(struct bshell_parse_ctx *ctx, struct bshell_ast_node **out)
|
||||
{
|
||||
bool ok = false;
|
||||
if (!ok && peek_arith_expr(ctx)) {
|
||||
ok = parse_arith_expr(ctx, BSHELL_PRECEDENCE_MINIMUM, out);
|
||||
}
|
||||
|
||||
if (!ok && peek_command(ctx)) {
|
||||
ok = parse_command(ctx, out);
|
||||
}
|
||||
|
||||
return ok;
|
||||
}
|
||||
Reference in New Issue
Block a user