1 <?xml version="1.0" encoding="UTF-8"?>
3 * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
4 * Copyright (C) 2006 - 2008 - INRIA
5 * Copyright (C) 2012 - 2016 - Scilab Enterprises
6 * Copyright (C) 2020 - Samuel GOUGEON
8 * This file is hereby licensed under the terms of the GNU GPL v2.0,
9 * pursuant to article 5.3.4 of the CeCILL v.2.1.
10 * This file was originally licensed under the terms of the CeCILL v2.1,
11 * and continues to be available under such terms.
12 * For more information, see the COPYING file which you should have received
13 * along with this program.
16 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"
17 xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML"
18 xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org"
19 xml:lang="en" xml:id="pause">
21 <refname>pause</refname>
23 temporarily pauses the running execution, and allows instructions in console.
33 <title>Description</title>
35 Switch to the <function>pause</function> mode.
36 Inserted in the code of a function, <function>pause</function> interrupts the execution
37 of the function: one receives a prompt symbol which indicates
38 the level of the <function>pause</function> (e.g. <literal>-1-></literal>).
39 The user is then in the workspace where the pause occurs, and where all the variables
40 around are accessible and can be changed by hand on purpose.
43 To resume the execution, enter <code>resume</code>.
46 Enter <code>abort</code> to definitively stop the execution and return to the main level.
49 The <function>pause</function> is very useful for debugging purposes.
53 <title>Examples</title>
54 <programlisting role="example"><![CDATA[
57 disp("Thanks to the pause, you can investigate if ''a'' has the right value");
58 disp("Values of local variables can be changed too if required.");
69 "Thanks to the pause, you can investigate if 'a' has the right value"
70 "Values of local variables can be changed too if required."
72 Type 'resume' or 'abort' to return to standard level prompt.
85 <refsection role="see also">
86 <title>See also</title>
87 <simplelist type="inline">
89 <link linkend="debug">debug</link>
92 <link linkend="halt">halt</link>
95 <link linkend="return">return</link>
98 <link linkend="abort">abort</link>
101 <link linkend="whereami">whereami</link>
104 <link linkend="sleep">sleep</link>
107 <link linkend="quit">quit</link>
111 <refsection role="history">
112 <title>History</title>
115 <revnumber>6.0.0</revnumber>
117 The new values of local variables changed during a pause are now taken
118 into account when resuming the execution with <literal>resume</literal>.