1
0
mirror of https://github.com/catseye/SixtyPical.git synced 2024-06-06 15:29:30 +00:00

Fix links in README. Implement Context.clone().

This commit is contained in:
Chris Pressey 2015-10-16 10:54:12 +01:00
parent dd4c50fc50
commit 9c201ccf07
2 changed files with 9 additions and 5 deletions

View File

@ -22,11 +22,9 @@ Documentation
-------------
* Design Goals — coming soon.
* [doc/SixtyPical.md](SixtyPical.md) — the spec
* [tests/SixtyPical Execution.md](SixtyPical Execution.md) —
literate test suite for running SixtyPical programs
* [tests/SixtyPical Analysis.md](SixtyPical Analysis.md) —
literate test suite for statically analyzing SixtyPical programs
* [SixtyPical specification](doc/SixtyPical.md)
* [Literate test suite for SixtyPical execution](tests/SixtyPical Execution.md)
* [Literate test suite for SixtyPical analysis](tests/SixtyPical Analysis.md)
TODO
----

View File

@ -48,6 +48,12 @@ class Context():
self._store.setdefault(ref.name, UNINITIALIZED)
self._writeables.add(ref.name)
def clone(self):
c = Context([], [], [])
c._store = dict(self._store)
c._writeables = set(self._writeables)
return c
def assertInitialized(self, *refs, **kwargs):
exception_class = kwargs.get('exception_class', UninitializedAccessError)
for ref in refs: