mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Remove parser error recovery mode
This commit is contained in:
@@ -1 +0,0 @@
|
||||
--error-recovery --ast-compact-json --pretty-json --hashes
|
||||
@@ -1,11 +0,0 @@
|
||||
Error: Expected primary expression.
|
||||
--> recovery_ast_constructor/input.sol:6:27:
|
||||
|
|
||||
6 | balances[tx.origin] = ; // missing RHS.
|
||||
| ^
|
||||
|
||||
Warning: Recovered in Statement at ';'.
|
||||
--> recovery_ast_constructor/input.sol:6:27:
|
||||
|
|
||||
6 | balances[tx.origin] = ; // missing RHS.
|
||||
| ^
|
||||
@@ -1 +0,0 @@
|
||||
1
|
||||
@@ -1,13 +0,0 @@
|
||||
// SPDX-License-Identifier: GPL-3.0
|
||||
pragma solidity >=0.0.0;
|
||||
|
||||
contract Error1 {
|
||||
constructor() {
|
||||
balances[tx.origin] = ; // missing RHS.
|
||||
}
|
||||
|
||||
// This function parses properly
|
||||
function five() public view returns(uint) {
|
||||
return 5;
|
||||
}
|
||||
}
|
||||
@@ -1 +0,0 @@
|
||||
--error-recovery
|
||||
@@ -1,5 +0,0 @@
|
||||
Error: Expected pragma, import directive or contract/interface/library/struct/enum/constant/function/error definition.
|
||||
--> recovery_ast_empty_contract/input.sol:3:1:
|
||||
|
|
||||
3 | c
|
||||
| ^
|
||||
@@ -1 +0,0 @@
|
||||
1
|
||||
@@ -1,3 +0,0 @@
|
||||
// SPDX-License-Identifier: GPL-3.0
|
||||
pragma 0.5.11;
|
||||
c
|
||||
@@ -1,18 +0,0 @@
|
||||
{
|
||||
"language": "Solidity",
|
||||
"sources":
|
||||
{
|
||||
"A":
|
||||
{
|
||||
"content": "// SPDX-License-Identifier: GPL-3.0\npragma solidity >=0.0; contract Errort6 { using foo for ; /* missing type name */ }"
|
||||
}
|
||||
},
|
||||
"settings":
|
||||
{
|
||||
"parserErrorRecovery": true,
|
||||
"outputSelection":
|
||||
{
|
||||
"*": { "": ["ast"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,46 +0,0 @@
|
||||
{
|
||||
"errors":
|
||||
[
|
||||
{
|
||||
"component": "general",
|
||||
"errorCode": "3546",
|
||||
"formattedMessage": "ParserError: Expected type name
|
||||
--> A:2:58:
|
||||
|
|
||||
2 | pragma solidity >=0.0; contract Errort6 { using foo for ; /* missing type name */ }
|
||||
| ^
|
||||
|
||||
",
|
||||
"message": "Expected type name",
|
||||
"severity": "error",
|
||||
"sourceLocation":
|
||||
{
|
||||
"end": 94,
|
||||
"file": "A",
|
||||
"start": 93
|
||||
},
|
||||
"type": "ParserError"
|
||||
},
|
||||
{
|
||||
"component": "general",
|
||||
"errorCode": "3796",
|
||||
"formattedMessage": "Warning: Recovered in ContractDefinition at '}'.
|
||||
--> A:2:84:
|
||||
|
|
||||
2 | pragma solidity >=0.0; contract Errort6 { using foo for ; /* missing type name */ }
|
||||
| ^
|
||||
|
||||
",
|
||||
"message": "Recovered in ContractDefinition at '}'.",
|
||||
"severity": "warning",
|
||||
"sourceLocation":
|
||||
{
|
||||
"end": 120,
|
||||
"file": "A",
|
||||
"start": 119
|
||||
},
|
||||
"type": "Warning"
|
||||
}
|
||||
],
|
||||
"sources": {}
|
||||
}
|
||||
Reference in New Issue
Block a user