aboutsummaryrefslogtreecommitdiffstats
path: root/test/compilationTests/stringutils
diff options
context:
space:
mode:
authorAnurag Dashputre <anurag4u80@gmail.com>2018-08-23 14:26:45 +0800
committerGitHub <noreply@github.com>2018-08-23 14:26:45 +0800
commit8497dcd721ff0a113374c0c1e1778d44265398a6 (patch)
tree2833ab7b3c7513647c0476d0e5d33dc11fcd6951 /test/compilationTests/stringutils
parent55524788e2829b3a2b9c6c513f78ba2074aa3385 (diff)
parent410d288dfc2e08c42df58c7e01ad5c332ce92727 (diff)
downloaddexon-solidity-8497dcd721ff0a113374c0c1e1778d44265398a6.tar
dexon-solidity-8497dcd721ff0a113374c0c1e1778d44265398a6.tar.gz
dexon-solidity-8497dcd721ff0a113374c0c1e1778d44265398a6.tar.bz2
dexon-solidity-8497dcd721ff0a113374c0c1e1778d44265398a6.tar.lz
dexon-solidity-8497dcd721ff0a113374c0c1e1778d44265398a6.tar.xz
dexon-solidity-8497dcd721ff0a113374c0c1e1778d44265398a6.tar.zst
dexon-solidity-8497dcd721ff0a113374c0c1e1778d44265398a6.zip
Merge branch 'develop' into anurag_issue_3667
Diffstat (limited to 'test/compilationTests/stringutils')
-rw-r--r--test/compilationTests/stringutils/strings.sol10
1 files changed, 5 insertions, 5 deletions
diff --git a/test/compilationTests/stringutils/strings.sol b/test/compilationTests/stringutils/strings.sol
index 6865664b..f89a2527 100644
--- a/test/compilationTests/stringutils/strings.sol
+++ b/test/compilationTests/stringutils/strings.sol
@@ -83,23 +83,23 @@ library strings {
uint ret;
if (self == 0)
return 0;
- if (self & 0xffffffffffffffffffffffffffffffff == 0) {
+ if (uint256(self) & 0xffffffffffffffffffffffffffffffff == 0) {
ret += 16;
self = bytes32(uint(self) / 0x100000000000000000000000000000000);
}
- if (self & 0xffffffffffffffff == 0) {
+ if (uint256(self) & 0xffffffffffffffff == 0) {
ret += 8;
self = bytes32(uint(self) / 0x10000000000000000);
}
- if (self & 0xffffffff == 0) {
+ if (uint256(self) & 0xffffffff == 0) {
ret += 4;
self = bytes32(uint(self) / 0x100000000);
}
- if (self & 0xffff == 0) {
+ if (uint256(self) & 0xffff == 0) {
ret += 2;
self = bytes32(uint(self) / 0x10000);
}
- if (self & 0xff == 0) {
+ if (uint256(self) & 0xff == 0) {
ret += 1;
}
return 32 - ret;