elisp @@ macro
[bpt/guile.git] / doc / ref / guile-invoke.texi
index 90922f2..bc33ce0 100644 (file)
@@ -1,6 +1,6 @@
 @c -*-texinfo-*-
 @c This is part of the GNU Guile Reference Manual.
-@c Copyright (C)  1996, 1997, 2000, 2001, 2002, 2003, 2004, 2005, 2010, 2011, 2013
+@c Copyright (C)  1996, 1997, 2000, 2001, 2002, 2003, 2004, 2005, 2010, 2011, 2013, 2014
 @c   Free Software Foundation, Inc.
 @c See the file guile.texi for copying conditions.
 
@@ -208,6 +208,35 @@ Treat the auto-compilation cache as invalid, forcing recompilation.
 @item --no-auto-compile
 Disable automatic source file compilation.
 
+@vnew{2.0.8}
+
+@item --language=@var{lang}
+For the remainder of the command line arguments, assume that files
+mentioned with @code{-l} and expressions passed with @code{-c} are
+written in @var{lang}.  @var{lang} must be the name of one of the
+languages supported by the compiler (@pxref{Compiler Tower}).  When run
+interactively, set the REPL's language to @var{lang} (@pxref{Using Guile
+Interactively}).
+
+The default language is @code{scheme}; other interesting values include
+@code{elisp} (for Emacs Lisp), and @code{ecmascript}.
+
+The example below shows the evaluation of expressions in Scheme, Emacs
+Lisp, and ECMAScript:
+
+@example
+guile -c "(apply + '(1 2))"
+guile --language=elisp -c "(= (funcall (symbol-function '+) 1 2) 3)"
+guile --language=ecmascript -c '(function (x) @{ return x * x; @})(2);'
+@end example
+
+To load a file written in Scheme and one written in Emacs Lisp, and then
+start a Scheme REPL, type:
+
+@example
+guile -l foo.scm --language=elisp -l foo.el --language=scheme
+@end example
+
 @vnew{2.0}
 
 @item -h@r{, }--help
@@ -298,7 +327,9 @@ variable.  By default, the history file is @file{$HOME/.guile_history}.
 @vindex GUILE_INSTALL_LOCALE
 This is a flag that can be used to tell Guile whether or not to install
 the current locale at startup, via a call to @code{(setlocale LC_ALL
-"")}.  @xref{Locales}, for more information on locales.
+"")}@footnote{The @code{GUILE_INSTALL_LOCALE} environment variable was
+ignored in Guile versions prior to 2.0.9.}.  @xref{Locales}, for more
+information on locales.
 
 You may explicitly indicate that you do not want to install
 the locale by setting @env{GUILE_INSTALL_LOCALE} to @code{0}, or
@@ -336,7 +367,7 @@ Here is an example using the Bash shell that adds the current directory,
 @example
 $ export GUILE_LOAD_COMPILED_PATH=".:../my-library"
 $ guile -c '(display %load-compiled-path) (newline)'
-(. ../my-library /usr/local/lib/guile/2.0/ccache)
+(. ../my-library /usr/local/lib/guile/2.2/ccache)
 @end example
 
 @item GUILE_LOAD_PATH
@@ -355,8 +386,8 @@ directory to @code{%load-path}, and adds the relative directory
 @example
 $ env GUILE_LOAD_PATH=".:...:../srfi" \
 guile -c '(display %load-path) (newline)'
-(. /usr/local/share/guile/2.0 \
-/usr/local/share/guile/site/2.0 \
+(. /usr/local/share/guile/2.2 \
+/usr/local/share/guile/site/2.2 \
 /usr/local/share/guile/site \
 /usr/local/share/guile \
 ../srfi)
@@ -381,14 +412,6 @@ Guile uses the environment variable @env{HOME}, the name of your home
 directory, to locate various files, such as @file{.guile} or
 @file{.guile_history}.
 
-@item LTDL_LIBRARY_PATH
-@vindex LTDL_LIBRARY_PATH
-Guile now adds its install prefix to the @env{LTDL_LIBRARY_PATH}.
-
-Users may now install Guile in non-standard directories and run
-`/path/to/bin/guile', without having also to set @env{LTDL_LIBRARY_PATH}
-to include `/path/to/lib'.
-
 @end table
 
 @c Local Variables: