Changes between Version 43 and Version 44 of ContractReduction


Ignore:
Timestamp:
12/14/15 10:53:04 (10 years ago)
Author:
zmanchun
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • ContractReduction

    v43 v44  
    1212* `reads` clause: specify memory locations read by the function, the syntax of which is similar to `assigns` clause
    1313* additional parameter for `allocates` clause: specify the scope of the heap for allocation; if absent then the root scope is used
    14 * wildcard term: `\everything`
     14* wildcard term: `...`
    1515
    1616{{{
     
    3535completeness-clause ::= complete behaviors (id (, id)∗)? ;
    3636                      | disjoint behaviors (id (, id)∗)? ;
    37 term ::= \old ( term ) | \result | \nothing | \everything
     37term ::= \old ( term ) | \result | \nothing | ...
    3838pred ::= \old ( pred )
    3939}}}
     
    6464[[* `mem1+mem2`, where `mem1` and `mem2` are expressions of type `$memory`.  This is the union of the two sets.]]  Problem this is ambiguous with numeric +, as in x+y.
    6565
    66 == `assigns` clause ==
     66== `assigns` and `reads` clause ==
    6767
    6868As in other contract specification language, this contract clause is used to specify a set of existing memory units.    The claim is that if an existing memory unit is not in the set, it will not be modified in the course of the function call.  The syntax is:
    6969
    70 `assigns location (, location)*` or `assigns \nothing` or `assigns $everything`
     70`assigns/reads location (, location)*` or `assigns/reads \nothing`
    7171
    7272where `location` is a `tset` expressions of type `$memory`.
     
    7777}}}
    7878
     79* absence of `assigns`/`reads` clause
     80 * for non-system functions, the function body is scanned to understand the memory locations assigned/read by it
     81 * for system functions, only memory locations reachable form the arguments shall be assigned/read
    7982
    8083== `depends` clause ==