summaryrefslogtreecommitdiffstats
path: root/parser.h
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2023-05-30 21:41:03 -0700
committerKaz Kylheku <kaz@kylheku.com>2023-05-30 21:41:03 -0700
commit6846740ce44659a1f31e01054b0f1bcc8dc04c7a (patch)
tree14912dd2d0ecd0702ca9d67d0fdd965d24a75478 /parser.h
parentd87f9b4b380df188a17b6c1b04c4d24d7d79f98e (diff)
downloadtxr-6846740ce44659a1f31e01054b0f1bcc8dc04c7a.tar.gz
txr-6846740ce44659a1f31e01054b0f1bcc8dc04c7a.tar.bz2
txr-6846740ce44659a1f31e01054b0f1bcc8dc04c7a.zip
command line: -e takes multiple forms.
* parser.[ch] (read_objects_from_string): New function. * txr.c (help): Update description of -e, and don't describe -p as being like -e. (txr_main): Implement -e using read_objects_from_string, with progn consed to the front. Don't evaluate if it returns the error value colon_k. * txr.1: Documentation updated.
Diffstat (limited to 'parser.h')
-rw-r--r--parser.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/parser.h b/parser.h
index 8e632c47..fe05b448 100644
--- a/parser.h
+++ b/parser.h
@@ -137,6 +137,8 @@ val get_json(val source_in, val error_stream, val error_return_val,
val name_in, val lineno);
val read_eval_stream(val self, val stream, val error_stream);
val read_compiled_file(val self, val stream, val error_stream);
+val read_objects_from_string(val string, val error_stream,
+ val error_return_val, val name_in);
val txr_parse(val source, val error_stream,
val error_return_val, val name_in);
val repl(val bindings, val in_stream, val out_stream, val env);