solidity/test/libsolidity/smtCheckerTests/functions/getters/string.sol
2021-07-16 14:43:52 +02:00

14 lines
347 B
Solidity

contract C {
string public str1 = 'b';
function f() public view {
string memory a1 = this.str1();
assert(keccak256(bytes(a1)) == keccak256(bytes(str1))); // should hold
assert(keccak256(bytes(a1)) == keccak256('a')); // should fail
}
}
// ====
// SMTEngine: all
// ----
// Warning 6328: (178-224): CHC: Assertion violation happens here.