diff options
| author | Rich Hickey <richhickey@gmail.com> | 2006-06-11 21:07:38 +0000 |
|---|---|---|
| committer | Rich Hickey <richhickey@gmail.com> | 2006-06-11 21:07:38 +0000 |
| commit | 48bd0825f45f2255d851ba0f3236a454f6178ae0 (patch) | |
| tree | 0a0fc414d2e80b70e9c4f8a318d7073978904024 /src/cli/runtime/Transaction.cs | |
| parent | 8671005cec92c0ad806828eb4df605b17aadae4c (diff) | |
made Objs based upon ArrayIdentityMap, allowed out-of-transaction reads of current vals
Diffstat (limited to 'src/cli/runtime/Transaction.cs')
| -rw-r--r-- | src/cli/runtime/Transaction.cs | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/cli/runtime/Transaction.cs b/src/cli/runtime/Transaction.cs index 21ff35bc..aaaac9dc 100644 --- a/src/cli/runtime/Transaction.cs +++ b/src/cli/runtime/Transaction.cs @@ -71,8 +71,11 @@ static public TRef tref(Object val) { }
static public Object get2(TRef tref) {
- return ThreadLocalData.getTransaction().get(tref);
-}
+ Transaction trans = ThreadLocalData.getTransaction();
+ if(trans != null)
+ return trans.get(tref);
+ return getCurrent(tref).val;
+ }
static public Object set2(TRef tref, Object val) {
return ThreadLocalData.getTransaction().set(tref,val);
|
