Skip to content

Commit 779b62d

Browse files
committed
fix issue with import attributes
1 parent 1748718 commit 779b62d

File tree

3 files changed

+17
-9
lines changed

3 files changed

+17
-9
lines changed

fortran-src.cabal

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cabal-version: 1.12
22

3-
-- This file has been generated from package.yaml by hpack version 0.35.2.
3+
-- This file has been generated from package.yaml by hpack version 0.36.0.
44
--
55
-- see: https://github.com/sol/hpack
66

@@ -15,7 +15,7 @@ author: Mistral Contrastin,
1515
Matthew Danish,
1616
Dominic Orchard,
1717
Andrew Rice
18-
maintainer: Dominic Orchard <[email protected]>
18+
maintainer: Dominic Orchard
1919
license: Apache-2.0
2020
license-file: LICENSE
2121
build-type: Simple
@@ -200,8 +200,8 @@ library
200200
, pretty >=1.1 && <2
201201
, process >=1.2.0.0
202202
, singletons ==3.0.*
203-
, singletons-base >=3.0 && <3.6
204-
, singletons-th >=3.0 && <3.6
203+
, singletons-base >=3.0 && <3.4
204+
, singletons-th >=3.0 && <3.4
205205
, temporary >=1.2 && <1.4
206206
, text >=1.2 && <2.2
207207
, uniplate >=1.6 && <2
@@ -264,8 +264,8 @@ executable fortran-src
264264
, pretty >=1.1 && <2
265265
, process >=1.2.0.0
266266
, singletons ==3.0.*
267-
, singletons-base >=3.0 && <3.6
268-
, singletons-th >=3.0 && <3.6
267+
, singletons-base >=3.0 && <3.4
268+
, singletons-th >=3.0 && <3.4
269269
, temporary >=1.2 && <1.4
270270
, text >=1.2 && <2.2
271271
, uniplate >=1.6 && <2

package.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ tested-with: GHC >= 9.0
1212
github: camfort/fortran-src
1313
bug-reports: https://github.com/camfort/fortran-src/issues
1414
author: [Mistral Contrastin, Matthew Danish, Dominic Orchard, Andrew Rice]
15-
maintainer: [[email protected], Ben Orchard]
15+
maintainer: [Dominic Orchard]
1616
category: Language
1717
license: Apache-2.0
1818
license-file: LICENSE

src/Language/Fortran/Parser/Free/Fortran2003.y

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -583,9 +583,9 @@ NONEXECUTABLE_STATEMENT :: { Statement A0 }
583583
| save { StSave () (getSpan $1) Nothing }
584584

585585
-- according to IBM F2003 docs, dcolon is always required
586-
| procedure '(' MAYBE_PROC_INTERFACE ')' ATTRIBUTE_LIST '::' PROC_DECLS
586+
| procedure '(' MAYBE_PROC_INTERFACE ')' MAYBE_ATTRIBUTE_LIST '::' PROC_DECLS
587587
{ let declAList = fromReverseList $7
588-
in StProcedure () (getTransSpan $1 $7) $3 (Just (fromReverseList $5)) declAList }
588+
in StProcedure () (getTransSpan $1 $7) $3 $5 declAList }
589589

590590
| dimension MAYBE_DCOLON INITIALIZED_DECLARATOR_LIST
591591
{ let declAList = fromReverseList $3
@@ -1038,6 +1038,14 @@ DECLARATION_STATEMENT :: { Statement A0 }
10381038
{ let { declAList = fromReverseList $2 }
10391039
in StDeclaration () (getTransSpan $1 declAList) $1 Nothing declAList }
10401040

1041+
MAYBE_ATTRIBUTE_LIST :: { Maybe (AList Attribute A0) }
1042+
: ',' NE_ATTRIBUTE_LIST { Just $ fromReverseList $2 }
1043+
| {- EMPTY -} { Nothing }
1044+
1045+
NE_ATTRIBUTE_LIST :: { [ Attribute A0 ] }
1046+
: NE_ATTRIBUTE_LIST ',' ATTRIBUTE_SPEC { $3 : $1 }
1047+
| ATTRIBUTE_SPEC { [ $1 ] }
1048+
10411049
ATTRIBUTE_LIST :: { [ Attribute A0 ] }
10421050
: ATTRIBUTE_LIST ',' ATTRIBUTE_SPEC { $3 : $1 }
10431051
| {- EMPTY -} { [ ] }

0 commit comments

Comments
 (0)