Skip to content

Commit ef96799

Browse files
committed
Fixes #65
1 parent 75d24e5 commit ef96799

File tree

2 files changed

+17
-1
lines changed

2 files changed

+17
-1
lines changed

server/src/antlr/vba.g4

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -427,7 +427,7 @@ constantName
427427
// ;
428428

429429
constDeclaration
430-
: variableModifier? CONST wsc constItemList
430+
: (variableModifier wsc)? CONST wsc constItemList
431431
;
432432

433433
constItemList

test/fixtures/ScopeDiagnostics.bas

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
Attribute VB_Name = "ScopeDiagnostics"
2+
3+
Option Explicit
4+
5+
Private Const ABC As Long = 0
6+
7+
Public Enum XfaskofeaFoo
8+
Enum1 = 2 ^ 1
9+
Bar = 2 ^ 2
10+
Bar = 2 ^ 3
11+
End Enum
12+
13+
Public Sub XfaskofeaFoo()
14+
Attribute XfaskofeaFoo.VB_Description = "docstring."
15+
16+
End Sub

0 commit comments

Comments
 (0)