Stratego/XT JIRA  History | Log In     View a printable version of the current page. Get help!  
Issue Details (XML | Word)

Key: STR-44
Type: Improvement Improvement
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Eelco Visser
Reporter: Anonymous
Votes: 0
Watchers: 1
Operations

Clone this issue
Create sub-task
If you were logged in you would be able to see more operations.
Stratego/XT

Redesign dynamic rules

Created: 2004-04-06 15:34   Updated: 2008-03-31 20:39
Component/s: strc - Stratego compiler
Affects Version/s: None
Fix Version/s: 0.10

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown
Issue Links:
Incorporate
This issue incorporates:
STR-19 Explicit scope identification for dyn... Major Closed
STR-18 Application of "extend dynamic rules... Major Closed
 
Solve
This issue will solve:
STR-8 Scopes and Undefined are reserved terms Major Closed
 


 Description  « Hide
Dynamic rules are used widely in Stratego programming and for other problems than originally envisioned. The implementation was extended
with operations for saving and restoring tables, intersection different tables, and rules producing a set (list) of results. It is
time that the whole implementation of dynamic rules is redesigned to
accomodate all these features in a clean manner.

Requirements:

* necessary operations:
  - add rule
  - lookup rule
  - remove rule
  - extend rule
  - new scope
  - end scope
  - label scope
  - indicate scope of rule using label
  - save ruleset
  - restore ruleset
  - intersection / union / ... of rulesets
  - change set (to delay changes to rule table)

* all operations should be efficient in time and space
  - no cloning of entire table for save/restore
  - add, lookup, remove should be O(1) or O(s), where
    s is the number of enclosing scopes
  - entering/exiting scope should be O(1)
  - saving and restoring should be O(1)
  - intersection ... should be O(n) (n number of rules)* extensions
  - 'extend' rules (bagof)
  - 'labels' to indicate scope (instead of override)

 All   Comments   Work Log   Change History      Sort Order:
Eelco Visser [2004-04-06 15:40]
Scopes and Undefine will probably disappear

Eelco Visser [2004-04-06 15:42]
This will not be done; only the rules that are visible
in the top scope will be visible; otherwise the scope mechanism has no use.

Arthur van Dam [2004-05-07 15:06]
Ongoing issue, but as it is right now, it's ready for 0.10!