aboutsummaryrefslogtreecommitdiffstats
path: root/vm.cpp
diff options
context:
space:
mode:
authorDaniel Hams <daniel.hams@gmail.com>2014-03-11 17:33:54 +0800
committerDaniel Hams <daniel.hams@gmail.com>2014-03-11 17:33:54 +0800
commit07e1b513bac15ae0cf50c01b6ca11a06293aa269 (patch)
tree0fce15b498b54799ad60896bd7357ffb08b6376f /vm.cpp
parent2b0b259f7bb633694f52bc0b2fe6c0ea0a819b2f (diff)
downloaddexon-solidity-07e1b513bac15ae0cf50c01b6ca11a06293aa269.tar
dexon-solidity-07e1b513bac15ae0cf50c01b6ca11a06293aa269.tar.gz
dexon-solidity-07e1b513bac15ae0cf50c01b6ca11a06293aa269.tar.bz2
dexon-solidity-07e1b513bac15ae0cf50c01b6ca11a06293aa269.tar.lz
dexon-solidity-07e1b513bac15ae0cf50c01b6ca11a06293aa269.tar.xz
dexon-solidity-07e1b513bac15ae0cf50c01b6ca11a06293aa269.tar.zst
dexon-solidity-07e1b513bac15ae0cf50c01b6ca11a06293aa269.zip
Remove clang bug workarounds fixed with latest XCode tools release.
Diffstat (limited to 'vm.cpp')
-rw-r--r--vm.cpp65
1 files changed, 0 insertions, 65 deletions
diff --git a/vm.cpp b/vm.cpp
index 7e744bec..f22dcaa5 100644
--- a/vm.cpp
+++ b/vm.cpp
@@ -45,31 +45,11 @@ public:
u256 store(u256 _n)
{
-#ifdef __clang__
- tuple<u256, u256, u256, map<u256, u256> > & address = addresses[myAddress];
- map<u256, u256> & third = get<3>(address);
- auto sFinder = third.find(_n);
- if (sFinder != third.end())
- return sFinder->second;
- else
- return 0;
-#else
return get<3>(addresses[myAddress])[_n];
-#endif
}
void setStore(u256 _n, u256 _v)
{
-#ifdef __clang__
- tuple<u256, u256, u256, map<u256, u256> > & address = addresses[myAddress];
- map<u256, u256> & third = get<3>(address);
- auto sFinder = third.find(_n);
- if (sFinder != third.end())
- sFinder->second = _v;
- else
- third.insert(std::make_pair(_n, _v));
-#else
get<3>(addresses[myAddress])[_n] = _v;
-#endif
}
void mktx(Transaction& _t)
{
@@ -86,17 +66,7 @@ public:
u256 txCount(Address _a) { return get<1>(addresses[_a]); }
u256 extro(Address _a, u256 _pos)
{
-#ifdef __clang__
- tuple<u256, u256, u256, map<u256, u256> > & address = addresses[_a];
- map<u256, u256> & third = get<3>(address);
- auto sFinder = third.find(_pos);
- if (sFinder != third.end())
- return sFinder->second;
- else
- return 0;
-#else
return get<3>(addresses[_a])[_pos];
-#endif
}
u256 extroPrice(Address _a) { return get<2>(addresses[_a]); }
void suicide(Address _a)
@@ -125,19 +95,7 @@ public:
get<1>(addresses[_a]) = _myNonce;
get<2>(addresses[_a]) = 0;
for (unsigned i = 0; i < _myData.size(); ++i)
-#ifdef __clang__
- {
- tuple<u256, u256, u256, map<u256, u256> > & address = addresses[_a];
- map<u256, u256> & third = get<3>(address);
- auto sFinder = third.find(i);
- if (sFinder != third.end())
- sFinder->second = _myData[i];
- else
- third.insert(std::make_pair(i, _myData[i]));
- }
-#else
get<3>(addresses[_a])[i] = _myData[i];
-#endif
}
mObject exportEnv()
@@ -245,36 +203,13 @@ public:
{
u256 adr(j.first);
for (auto const& k: j.second.get_array())
-#ifdef __clang__
- {
- map<u256, u256> & third = get<3>(a);
- auto sFinder = third.find(adr);
- if (sFinder != third.end())
- sFinder->second = toInt(k);
- else
- third.insert(std::make_pair(adr, toInt(k)));
- adr++;
- }
-#else
get<3>(a)[adr++] = toInt(k);
-#endif
}
if (o.count("code"))
{
u256s d = compileLisp(o["code"].get_str());
for (unsigned i = 0; i < d.size(); ++i)
-#ifdef __clang__
- {
- map<u256, u256> & third = get<3>(a);
- auto sFinder = third.find(i);
- if (sFinder != third.end())
- sFinder->second = d[i];
- else
- third.insert(std::make_pair(i, d[i]));
- }
-#else
get<3>(a)[(u256)i] = d[i];
-#endif
}
}
}