Changes between Version 42 and Version 43 of ContractReduction


Ignore:
Timestamp:
12/14/15 10:44:25 (10 years ago)
Author:
zmanchun
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • ContractReduction

    v42 v43  
    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`
    1415
    1516{{{
     
    315316
    316317{{{
    317 /*@ depends \read(q->owner)+\write(q->owner);
     318/*@ depends \read(q->owner), \write(q->owner);
    318319  @ assigns q->owner;
    319320*/
    320321$atomic_f _Bool lock(cqueue* q)
    321   $depends {$access(q->owner)}
    322   $assigns {q->owner}
    323322{
    324323  if(q->owner==$self)
     
    333332
    334333{{{
    335 /*@ depends \calls(enqueue, q, ...)+$calls(dequeue,q, ...);
     334/*@ depends \calls(enqueue, q, ...), $calls(dequeue,q, ...);
    336335  @ reads q->data;
    337336  @ assigns \nothing;
     
    347346  @ behavior success:
    348347  @   assumes q->owner==$self;
    349   @   $depends $access(q->owner);
     348  @   depends \access(q->owner);
    350349  @   assigns q->owner;
    351350  @ behavior failure:
    352351  @   assumes q->owner!=$self;
    353   @   $depends \nothing;
     352  @   depends \nothing;
    354353  @   assigns \nothing;
    355354  @*/