mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Merge pull request #13109 from sourabhxyz/develop
Fix commandline tests not detecting a snippet with a broken free function definition
This commit is contained in:
commit
cf1b9a5241
@ -87,7 +87,6 @@ instead of library functions.
|
|||||||
}
|
}
|
||||||
|
|
||||||
function contains(Data storage self, uint value)
|
function contains(Data storage self, uint value)
|
||||||
public
|
|
||||||
view
|
view
|
||||||
returns (bool)
|
returns (bool)
|
||||||
{
|
{
|
||||||
|
@ -517,15 +517,16 @@ SOLTMPDIR=$(mktemp -d)
|
|||||||
opts=()
|
opts=()
|
||||||
# We expect errors if explicitly stated, or if imports
|
# We expect errors if explicitly stated, or if imports
|
||||||
# are used (in the style guide)
|
# are used (in the style guide)
|
||||||
if grep -E "This will not compile|import \"" "$f" >/dev/null
|
if grep -E "// This will not compile" "$f" >/dev/null ||
|
||||||
|
sed -e 's|//.*||g' "$f" | grep -E "import \"" >/dev/null
|
||||||
then
|
then
|
||||||
opts=(--expect-errors)
|
opts=(--expect-errors)
|
||||||
fi
|
fi
|
||||||
if grep "This will report a warning" "$f" >/dev/null
|
if grep "// This will report a warning" "$f" >/dev/null
|
||||||
then
|
then
|
||||||
opts+=(--expect-warnings)
|
opts+=(--expect-warnings)
|
||||||
fi
|
fi
|
||||||
if grep "This may report a warning" "$f" >/dev/null
|
if grep "// This may report a warning" "$f" >/dev/null
|
||||||
then
|
then
|
||||||
opts+=(--ignore-warnings)
|
opts+=(--ignore-warnings)
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user