aboutsummaryrefslogtreecommitdiffstats
path: root/test/libsolidity
diff options
context:
space:
mode:
authorchriseth <c@ethdev.com>2015-09-24 16:23:35 +0800
committerchriseth <c@ethdev.com>2015-09-24 16:23:35 +0800
commit52f7e3584350a3d204542ccc982c0951f4c94dc7 (patch)
treefb37a3e6d0694468ce25fe6fa3b0dfa7dc924f4f /test/libsolidity
parent4a2114ba35eae0a9dae5be2526d107dd19d33baf (diff)
parent8a9b9e4fdbead915da0dd725d3dc0ffe45d84065 (diff)
downloaddexon-solidity-52f7e3584350a3d204542ccc982c0951f4c94dc7.tar.gz
dexon-solidity-52f7e3584350a3d204542ccc982c0951f4c94dc7.tar.zst
dexon-solidity-52f7e3584350a3d204542ccc982c0951f4c94dc7.zip
Merge pull request #91 from chriseth/literalStringsToStoragePointer
Literal strings to storage pointer
Diffstat (limited to 'test/libsolidity')
-rw-r--r--test/libsolidity/SolidityNameAndTypeResolution.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/libsolidity/SolidityNameAndTypeResolution.cpp b/test/libsolidity/SolidityNameAndTypeResolution.cpp
index 8346b8ca..cac16682 100644
--- a/test/libsolidity/SolidityNameAndTypeResolution.cpp
+++ b/test/libsolidity/SolidityNameAndTypeResolution.cpp
@@ -2308,6 +2308,16 @@ BOOST_AUTO_TEST_CASE(array_out_of_bound_access)
SOLIDITY_CHECK_ERROR_TYPE(parseAndAnalyseReturnError(text), TypeError);
}
+BOOST_AUTO_TEST_CASE(literal_string_to_storage_pointer)
+{
+ char const* text = R"(
+ contract C {
+ function f() { string x = "abc"; }
+ }
+ )";
+ SOLIDITY_CHECK_ERROR_TYPE(parseAndAnalyseReturnError(text), TypeError);
+}
+
BOOST_AUTO_TEST_SUITE_END()
}