Skip to content

Commit c503a04

Browse files
committed
Allow type/class in implicit statements
1 parent 9f76f77 commit c503a04

File tree

5 files changed

+109487
-109420
lines changed

5 files changed

+109487
-109420
lines changed

grammar.js

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -616,7 +616,10 @@ module.exports = grammar({
616616
caseInsensitive('implicit'),
617617
choice(
618618
commaSep1(seq(
619-
$.intrinsic_type,
619+
choice(
620+
$.intrinsic_type,
621+
$.derived_type
622+
),
620623
'(',
621624
commaSep1($.implicit_range),
622625
')'
@@ -842,7 +845,10 @@ module.exports = grammar({
842845
procedure_declaration: $ => seq(
843846
caseInsensitive('procedure'),
844847
optional(seq(
845-
'(', optional(alias($.identifier, $.procedure_interface)), ')'
848+
'(',
849+
optional(
850+
alias($.identifier, $.procedure_interface)),
851+
')'
846852
)),
847853
optional(seq(',', commaSep1($.procedure_attribute))),
848854
),

src/grammar.json

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9645,8 +9645,17 @@
96459645
"type": "SEQ",
96469646
"members": [
96479647
{
9648-
"type": "SYMBOL",
9649-
"name": "intrinsic_type"
9648+
"type": "CHOICE",
9649+
"members": [
9650+
{
9651+
"type": "SYMBOL",
9652+
"name": "intrinsic_type"
9653+
},
9654+
{
9655+
"type": "SYMBOL",
9656+
"name": "derived_type"
9657+
}
9658+
]
96509659
},
96519660
{
96529661
"type": "STRING",
@@ -9696,8 +9705,17 @@
96969705
"type": "SEQ",
96979706
"members": [
96989707
{
9699-
"type": "SYMBOL",
9700-
"name": "intrinsic_type"
9708+
"type": "CHOICE",
9709+
"members": [
9710+
{
9711+
"type": "SYMBOL",
9712+
"name": "intrinsic_type"
9713+
},
9714+
{
9715+
"type": "SYMBOL",
9716+
"name": "derived_type"
9717+
}
9718+
]
97019719
},
97029720
{
97039721
"type": "STRING",

src/node-types.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3284,6 +3284,10 @@
32843284
"multiple": true,
32853285
"required": true,
32863286
"types": [
3287+
{
3288+
"type": "derived_type",
3289+
"named": true
3290+
},
32873291
{
32883292
"type": "implicit_range",
32893293
"named": true

0 commit comments

Comments
 (0)