From 3100d6b64d886b138ce3866df561057651371818 Mon Sep 17 00:00:00 2001 From: Marshall Lochbaum Date: Mon, 22 Nov 2021 17:57:14 -0500 Subject: =?UTF-8?q?Specify=20=E2=80=A2SH?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/spec/system.html | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'docs/spec/system.html') diff --git a/docs/spec/system.html b/docs/spec/system.html index 359e64bc..41b98728 100644 --- a/docs/spec/system.html +++ b/docs/spec/system.html @@ -312,6 +312,22 @@

•Out prints a string to stdout, with a trailing newline. •Show displays a BQN value to the programmer (the representation is not specified, and does not need to be plain text). •Fmt returns a string (not a character table: lines are separated by linefeeds) indicating how 𝕩 would be printed by the interactive environment. Both •Show and •Fmt may take a left argument configuring how the value should be formatted.

•Repr attempts to return a string so that •BQN •Repr 𝕩 matches 𝕩. If 𝕩 contains any mutable values (operations or namespaces), this is not possible. However, if such a values is stateless, in the sense that they don't access variables outside of their own scopes, it is permissible for •Repr to return source code that would create a value with identical behavior.

+

Interface

+ + + + + + + + + + + + + +
NameSummary
•SHExecute shell command and return exitcodestdoutstderr
+

The argument to •SH is a list of strings giving the command and its arguments (for example "mv""old""new"). The command is executed synchronously, and the result is a list of three elements: the command's exit code, text written to stdout, and text written to stderr. In both cases the text is a plain string containing all text emitted by the program. Text is interpreted as UTF-8, with an error if it's not valid UTF-8.

Operation properties

-- cgit v1.2.3