mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Add new tests.
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
abstract abstract contract A { constructor() public {} }
|
||||
// ----
|
||||
// ParserError: (9-17): Contract expected.
|
||||
@@ -0,0 +1 @@
|
||||
abstract contract A { constructor() public {} }
|
||||
@@ -0,0 +1,3 @@
|
||||
abstract interface A { }
|
||||
// ----
|
||||
// ParserError: (0-8): Only contracts can be abstract.
|
||||
@@ -0,0 +1,3 @@
|
||||
abstract library A { }
|
||||
// ----
|
||||
// ParserError: (0-8): Only contracts can be abstract.
|
||||
@@ -0,0 +1,5 @@
|
||||
contract A {
|
||||
function a() public;
|
||||
}
|
||||
// ----
|
||||
// TypeError: (0-39): Contract "A" should be marked as abstract.
|
||||
@@ -0,0 +1,7 @@
|
||||
abstract contract A {
|
||||
function a() public;
|
||||
}
|
||||
contract B is A {
|
||||
}
|
||||
// ----
|
||||
// TypeError: (49-68): Contract "B" should be marked as abstract.
|
||||
Reference in New Issue
Block a user