Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:Ledest:erlang:23
erlang
0648-ei-Document-allowed-arguments-to-erl_call-...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0648-ei-Document-allowed-arguments-to-erl_call-a.patch of Package erlang
From d7e9c0f38af73b465206682b4d26cb328aa484b3 Mon Sep 17 00:00:00 2001 From: Lukas Larsson <lukas@erlang.org> Date: Fri, 13 Aug 2021 09:36:00 +0200 Subject: [PATCH 2/2] ei: Document allowed arguments to erl_call -a --- lib/erl_interface/doc/src/erl_call_cmd.xml | 6 +++++- lib/erl_interface/src/prog/erl_call.c | 4 +++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/lib/erl_interface/doc/src/erl_call_cmd.xml b/lib/erl_interface/doc/src/erl_call_cmd.xml index 19b159d7a3..666cbb6dc4 100644 --- a/lib/erl_interface/doc/src/erl_call_cmd.xml +++ b/lib/erl_interface/doc/src/erl_call_cmd.xml @@ -72,7 +72,11 @@ <c>Fun</c> and <c>Args</c>, respectively. <c>Args</c> is to be in the same format as for <seemfa marker="erts:erlang#apply/3"> - <c>erlang:apply/3</c></seemfa> in <c>ERTS</c>.</p> + <c>erlang:apply/3</c></seemfa> in <c>ERTS</c> except only a + subset of all terms are allowed. The allowed term types are: + <c>list</c> (and <c>string</c> representation of list, that is "example"), + <c>tuple</c>, <c>atom</c> and <c>number</c>. + </p> <p>Notice that this flag takes exactly one argument, so quoting can be necessary to group <c>Mod</c>, <c>Fun</c>, and <c>Args</c> in a manner diff --git a/lib/erl_interface/src/prog/erl_call.c b/lib/erl_interface/src/prog/erl_call.c index 8caf218e0e..b8e11c3f86 100644 --- a/lib/erl_interface/src/prog/erl_call.c +++ b/lib/erl_interface/src/prog/erl_call.c @@ -645,7 +645,9 @@ int main(int argc, char *argv[]) ei_x_new(&e); /* No version to ei_rpc() */ if (ei_x_format_wo_ver(&e, args) < 0) { - /* FIXME no error message and why -1 ? */ + fprintf(stderr, "erl_call: Failed to parse arguments,\n" + "see the documentation for allowed term types.\n" + "Arguments: %s\n", args); exit(-1); } -- 2.31.1
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor