Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improved Syntax for Framing #86

Open
DavePearce opened this issue Jan 28, 2021 · 1 comment
Open

Improved Syntax for Framing #86

DavePearce opened this issue Jan 28, 2021 · 1 comment

Comments

@DavePearce
Copy link
Member

(see also #82)

I need to update this RFC: https://github.com/Whiley/RFCs/blob/master/text/0067-old-values.md

I think we need to separate out two things:

  1. The value of a variable in the pre-state
  2. The value of the heap in the pre-state

Currently, the proposal allows an arbitrary "old expression" form '*e' with an eye to eventually allowing 'e'`. I think there are some ambiguities here though. What is the meaning of these forms?

  • '*v' --- value in _old_ heap identified by _current_ value of v`
  • '*'v --- value in old heap identified by old value of v
  • '**v --- value in old heap identified by value in old or new heap identified by current value of v.

This is not making sense. We want two expression forms:

  • #e the value in the old heap identified by e. This is like *e but for the old heap.
  • 'v the old value of variable v.

Now, we can disambiguate the last case above as either ##v or #*v.

What about method calls? Do we need a syntax like m#() or similar?

@DavePearce
Copy link
Member Author

At this stage, it seems like going with old(e) for now makes the most sense.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant