mirror of
https://github.com/EiffelSoftware/eiffel-org.git
synced 2025-12-08 15:52:26 +01:00
Added release 19.05.
git-svn-id: https://svn.eiffel.com/eiffel-org/trunk@2152 abb3cda0-5349-4a8f-a601-0c33ac3a8c38
This commit is contained in:
@@ -0,0 +1,44 @@
|
||||
[[Property:title|Evaluation tool or Watch tool]]
|
||||
[[Property:weight|1]]
|
||||
[[Property:uuid|e70d5827-a00d-47ee-9e7a-b7b4bfb34ccf]]
|
||||
The Evaluation (or Watch) tool displays a list of expressions and their values (provided that those values can be obtained).
|
||||
|
||||
[[Image:expression-evaluation-tool]]
|
||||
|
||||
In the display, the ''Expression'' column gives the expression's text. The ''Context'' column gives the context in which the [[New expression dialog|expression]] is evaluated. The ''Value'' column gives the result of the expression, and the ''Type'' column the type of the expression's value.
|
||||
|
||||
In the image above, you can see various expressions. Look at the one on the fourth line. This is an object that has been dropped on to the Evaluation tool, and the tool displayed it as itself, as shown by "As object" in the ''Context'' column, and by the italic style. The user can name the dropped object by editing the value in the ''Expression'' column for the expression. This can be useful to help you remember the origin of the value.
|
||||
|
||||
The expression in the fifth row has an error, the icon is different, and the ''Value'' shows there is an error, double click on it for more details.
|
||||
|
||||
|
||||
{{tip|If the expression returns a non-Void (and non-basic type) object, then the corresponding row in the list is pickable. The object can be dropped, for example, on the Evaluation tool to inspect it or to keep the object visible while stepping through system execution. }}
|
||||
|
||||
|
||||
{{tip|holding the mouse pointer over the expression's cell will pop up a tooltip with details on the pointed expression }}
|
||||
|
||||
|
||||
On top of the list, four buttons can be found.
|
||||
* the button [[Image:toolbar-dropdown-icon]] is used to create/close watch tools via a menu popup
|
||||
* [[Image:debugger-auto-values]] Enable or disable auto expressions.
|
||||
* [[Image:new-expression-icon]] pops up the [[New expression dialog|expression definition dialog]], and can be used to define new expressions. If you have selected text in the editor, this text will be used to create the expression.
|
||||
* [[Image:general-edit-icon]] edits a currently selected expression (it is not possible to change the context of an expression, only the expression itself). The associated key shortcut is F2.
|
||||
* [[Image:general-toogle-icon]] disable/enable the evaluation of the selected expressions from the list. <br/>
|
||||
|
||||
* [[Image:debugger-set-sizes-icon]] set the slice limits of dropped <eiffel>SPECIAL</eiffel> or <eiffel>NATIVE_ARRAY</eiffel> objects. <br/>
|
||||
|
||||
* [[Image:debugger-show-hex-value-icon]] Toggle format display of numeric between decimal and hexadecimal format. <br/>
|
||||
|
||||
* [[Image:debugger-expand-info-icon]] This command can give an [[Object Viewer (also known as Expanded display)|expanded display]] of the string relative to an object, by dropping the object onto the button (or pressing <code>CTRL</code>+<code>E</code> on the selected value). Use it if an object has a very long string representation or a string representation that contains carriage returns, for example. <br/>
|
||||
|
||||
* [[Image:execution-object-storage-icon]] This button is used to remotely store or load a "stored" object (check [[Debuggee's Object Storage|remote object storage]]). <br/>
|
||||
|
||||
* [[Image:general-delete-icon]] removes the selected expressions from the list. The associated key shortcut is Del.
|
||||
* And the last two buttons are used to move up and down the expressions. You can also move the expressions up and down using <code>CTRL</code>+<code>-</code> or <code>CTRL</code>+<code>+</code> respectively (that is, the Control key with the ''minus'' key or the Control key with the ''plus'' key).
|
||||
|
||||
{{tip|Dropping an object onto this list lets you define quickly an expression whose context is the dropped object. This avoids having to type object addresses manually. <br/>
|
||||
If you hold the <code>CTRL</code> key while dropping, you will add the dropped object as itself. }}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
[[Property:title|Expression evaluation]]
|
||||
[[Property:weight|-10]]
|
||||
[[Property:uuid|e55442ac-7861-1995-d315-baeed6c49223]]
|
||||
[[Image:expression-evaluation-tool]]
|
||||
|
||||
The Expression evaluation tool (sometimes called the Watch tool) makes it possible to evaluate expressions while the application is stopped in the debugger. A typical use for it is the case in which you would like to know the result that an external feature would return. Since you do not have access to the C memory of the application, doing this would be impossible without the Expression evaluation tool. You might also want to know the result of an Eiffel feature whose body is too complex for you to evaluate.
|
||||
|
||||
In these cases (and any other that suits you), you should use the dynamic expression evaluation. Simply [[New expression dialog|define the expression]] and its result will be immediately available in the [[Evaluation tool or Watch tool|list of expressions]] .
|
||||
|
||||
If you keep the mouse cursor over the expression cell of line, you get a tooltip describing the expression result.
|
||||
|
||||
You can disable the evaluation of the selected expression by clicking on [[Image:general-toogle-icon]] . After you do, the context value will display 'disabled'.
|
||||
|
||||
If the expression has an error, or if the evaluation raised an exception, you can obtain a more detailed description by double-clicking on the expression row.
|
||||
|
||||
|
||||
{{caution|During the evaluation of an expression, all features that are necessary to obtain the result are called. Therefore, you should avoid calling queries that have side-effects, since doing so may alter the program execution. The Eiffel methodology recommends against creating queries with side-effects for other important reasons, as well. }}
|
||||
|
||||
{{caution|Eiffel ''agents'' (for example: <code>agent my_function</code>) are not supported is not supported. }}
|
||||
|
||||
{{caution|The evaluation ignores void-safety checking, a side effect is that expression <code>{FOO}</code> is interpreted as <code>{detachable FOO}</code> even if your application is void-safe. Thus keep this in mind when your expression implies <code>TYPE</code> objects. }}
|
||||
|
||||
|
||||
{{caution|Currently, for classic Eiffel systems, evaluating <code>Precursor</code> will result the current feature's result (not the precursor). }}
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
[[Property:title|New expression dialog]]
|
||||
[[Property:weight|2]]
|
||||
[[Property:uuid|95a78497-434d-759f-fdce-f9025c891495]]
|
||||
Adding new expressions to the [[Evaluation tool or Watch tool|list of expressions]] that should be dynamically evaluated is performed via a dialog.
|
||||
|
||||
|
||||
{|
|
||||
|-
|
||||
| [[Image:new-expression-definition-dlg]] <br/>
|
||||
context: Current feature
|
||||
| [[Image:new-expression-as-object-definition-dlg]] <br/>
|
||||
context: As object
|
||||
|}
|
||||
|
||||
|
||||
The first part in the dialog makes it possible to select the context of the expression.
|
||||
* The default context is the context of the [[Information relative to a stack element|currently selected call stack element]], as shown in the left image above. This context gives access to the locals, the arguments, the result and the enclosing object features.
|
||||
* The object context, that requires a valid object address, gives access to the features of the selected object. If you select "As object", the result of the expression is the referenced object itself; and you can supply a name for the object, as depicted in the right image above.
|
||||
* The last context, the class-related context, gives access to the <code>once</code> and constant features of that class. It requires a valid class name.
|
||||
|
||||
|
||||
The second part prompts for the expression itself. This field supports arguments, dot calls and operators (to a certain extent), but does not support creation expressions, agents or non-object calls. Genericity is partially supported.
|
||||
|
||||
The "Keep Assertion Checking" checkbox is used to enable assertion checking during expression evaluation if desired (by default assertions won't be checked).
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user