From f247d246725d76412242e547e7c212bf947542f8 Mon Sep 17 00:00:00 2001
From: Hans Bolinder
Date: Mon, 18 Mar 2013 15:31:07 +0100
Subject: Let escript recognize an encoding comment on the second line
The manual says that an Emacs directive can be placed on the second
line. With this patch that directive is also recognized when selecting
encoding of the script.
---
erts/doc/src/escript.xml | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
(limited to 'erts')
diff --git a/erts/doc/src/escript.xml b/erts/doc/src/escript.xml
index 66e904f64f..9e2a87dde6 100644
--- a/erts/doc/src/escript.xml
+++ b/erts/doc/src/escript.xml
@@ -4,7 +4,7 @@
+
+ If there is a comment selecting the encoding it can be
+ located on the second line.
+
On the third line (or second line depending on the presence
of the Emacs directive), it is possible to give arguments to
the emulator, such as
@@ -133,7 +138,9 @@ halt(1).
-include_lib("kernel/include/file.hrl").
to include the record definitions for the records used by the
- file:read_link_info/1 function.
+ file:read_link_info/1 function. You can also select
+ encoding here, but if there is a valid encoding comment on
+ the second line it takes precedence.
The script will be checked for syntactic and semantic
correctness before being run. If there are warnings (such as
--
cgit v1.2.3