Changes between Version 1 and Version 2 of SemanticQuery/ExpressionEntity


Ignore:
Timestamp:
Apr 19, 2012, 8:53:23 AM (13 years ago)
Author:
manualwiki
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • SemanticQuery/ExpressionEntity

    v1 v2  
    1010The following selectors work on expression entities. 
    1111 
    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}}}. 
     12Note that an expression is always treated as a single unit with its subexpressions, even in case expressions with more clauses, like {{{if}}} or {{{case}}}. 
    1313 
    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.'' 
    1515 
    1616* {{{fundef}}} (''function''): returns the function entity which contains the expression. 
     
    2222* {{{top}}} (''expression''): returns the expression's top-level expression. 
    2323* {{{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. 
    2626 
    2727== Properties == 
     
    2929These properties are defined for expression entities. 
    3030 
    31 Note that some of them depends of the context of the expression, which makes possible selecting tail calls or indexing function arguments. 
     31Note that some of them depends on the context of the expression, which makes possible selecting tail calls or indexing function arguments. 
    3232 
    3333* {{{type}}} (''atom''): returns the type of the expression. The type can 
     
    6666 
    6767* {{{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}}}. 
    6969* {{{last}}} (''bool''): returns true if the expression is the last expression of the clause. 
    7070* {{{index}}} (''int''): returns the index of the expression in the containing expression list.