mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Adds natspec to AST for enum definition.
This commit is contained in:
committed by
Nikola Matic
parent
7b634152bd
commit
be8752b5d3
@@ -0,0 +1,48 @@
|
||||
{
|
||||
"absolutePath": "a",
|
||||
"exportedSymbols":
|
||||
{
|
||||
"Color":
|
||||
[
|
||||
4
|
||||
]
|
||||
},
|
||||
"id": 5,
|
||||
"nodeType": "SourceUnit",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"canonicalName": "Color",
|
||||
"documentation":
|
||||
{
|
||||
"id": 1,
|
||||
"nodeType": "StructuredDocumentation",
|
||||
"src": "0:112:1",
|
||||
"text": "@title example of title\n @author example of author\n @notice example of notice\n @dev example of dev"
|
||||
},
|
||||
"id": 4,
|
||||
"members":
|
||||
[
|
||||
{
|
||||
"id": 2,
|
||||
"name": "Red",
|
||||
"nameLocation": "129:3:1",
|
||||
"nodeType": "EnumValue",
|
||||
"src": "129:3:1"
|
||||
},
|
||||
{
|
||||
"id": 3,
|
||||
"name": "Green",
|
||||
"nameLocation": "138:5:1",
|
||||
"nodeType": "EnumValue",
|
||||
"src": "138:5:1"
|
||||
}
|
||||
],
|
||||
"name": "Color",
|
||||
"nameLocation": "117:5:1",
|
||||
"nodeType": "EnumDefinition",
|
||||
"src": "112:33:1"
|
||||
}
|
||||
],
|
||||
"src": "112:34:1"
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
/// @title example of title
|
||||
/// @author example of author
|
||||
/// @notice example of notice
|
||||
/// @dev example of dev
|
||||
enum Color {
|
||||
Red,
|
||||
Green
|
||||
}
|
||||
|
||||
// ----
|
||||
@@ -0,0 +1,40 @@
|
||||
{
|
||||
"absolutePath": "a",
|
||||
"id": 5,
|
||||
"nodeType": "SourceUnit",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"documentation":
|
||||
{
|
||||
"id": 1,
|
||||
"nodeType": "StructuredDocumentation",
|
||||
"src": "0:112:1",
|
||||
"text": "@title example of title\n @author example of author\n @notice example of notice\n @dev example of dev"
|
||||
},
|
||||
"id": 4,
|
||||
"members":
|
||||
[
|
||||
{
|
||||
"id": 2,
|
||||
"name": "Red",
|
||||
"nameLocation": "129:3:1",
|
||||
"nodeType": "EnumValue",
|
||||
"src": "129:3:1"
|
||||
},
|
||||
{
|
||||
"id": 3,
|
||||
"name": "Green",
|
||||
"nameLocation": "138:5:1",
|
||||
"nodeType": "EnumValue",
|
||||
"src": "138:5:1"
|
||||
}
|
||||
],
|
||||
"name": "Color",
|
||||
"nameLocation": "117:5:1",
|
||||
"nodeType": "EnumDefinition",
|
||||
"src": "112:33:1"
|
||||
}
|
||||
],
|
||||
"src": "112:34:1"
|
||||
}
|
||||
Reference in New Issue
Block a user