Changes between Version 1 and Version 2 of SemanticQuery/ExpressionEntity
- Timestamp:
- Apr 19, 2012, 8:53:23 AM (13 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
SemanticQuery/ExpressionEntity
v1 v2 10 10 The following selectors work on expression entities. 11 11 12 Note that an expression is always treated as a single unit with its subexpressions, even in case expressions with more clauses like {{{if}}} or {{{case}}}.12 Note that an expression is always treated as a single unit with its subexpressions, even in case expressions with more clauses, like {{{if}}} or {{{case}}}. 13 13 14 '' After the name of the selector between parentheses you can find the type of the elements in the resulted set.''14 ''In parentheses you find the type of the result elements.'' 15 15 16 16 * {{{fundef}}} (''function''): returns the function entity which contains the expression. … … 22 22 * {{{top}}} (''expression''): returns the expression's top-level expression. 23 23 * {{{file}}} (''file''): returns the file entity where the expression is located. 24 * {{{origin}}} (''expression''): this is an experimental selector, which returns the origin of the expression's value determined by [wiki:DataFlow data flow analysis].25 * {{{reach}}} (''expression''): this is an experimental selector, which returns the places where the expression's value is copied, determined by [wiki:DataFLow data flow analysis].24 * {{{origin}}} (''expression''): returns the origin of the expression's value determined by data-flow analysis. 25 * {{{reach}}} (''expression''): returns the places where the expression's value is copied, determined by data-flow analysis. 26 26 27 27 == Properties == … … 29 29 These properties are defined for expression entities. 30 30 31 Note that some of them depends o fthe context of the expression, which makes possible selecting tail calls or indexing function arguments.31 Note that some of them depends on the context of the expression, which makes possible selecting tail calls or indexing function arguments. 32 32 33 33 * {{{type}}} (''atom''): returns the type of the expression. The type can … … 66 66 67 67 * {{{value}}}: returns the value of the expression. It is either the value of a constant expression or an operator of an operator-based expression. 68 * {{{class}}} (''atom''): returns the class of the expression: it either can be{{{expr}}} (stands for single expressions), {{{pattern}}}, or {{{guard}}}.68 * {{{class}}} (''atom''): returns the class of the expression: it can be either {{{expr}}} (stands for single expressions), {{{pattern}}}, or {{{guard}}}. 69 69 * {{{last}}} (''bool''): returns true if the expression is the last expression of the clause. 70 70 * {{{index}}} (''int''): returns the index of the expression in the containing expression list.