diff options
Diffstat (limited to 'src/Language/Fiddle/Ast')
-rw-r--r-- | src/Language/Fiddle/Ast/Internal/SyntaxTree.hs | 8 | ||||
-rw-r--r-- | src/Language/Fiddle/Ast/Internal/Util.hs | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/Language/Fiddle/Ast/Internal/SyntaxTree.hs b/src/Language/Fiddle/Ast/Internal/SyntaxTree.hs index 613dae4..063913b 100644 --- a/src/Language/Fiddle/Ast/Internal/SyntaxTree.hs +++ b/src/Language/Fiddle/Ast/Internal/SyntaxTree.hs @@ -96,7 +96,7 @@ data QRegMetadata (checkStage :: Bool) where -- emit getters and setters. regIsUnnamed :: Bool, -- | Full path to the register. - regFullPath :: NonEmpty String + regFullPath :: QualifiedPath String } -> QRegMetadata checkStage deriving (Generic, ToJSON) @@ -108,7 +108,7 @@ deriving instance data QBitsMetadata (checkStage :: Bool) where QBitsMetadata :: { bitsSpan :: When checkStage (FieldSpan Bits), - bitsFullPath :: NonEmpty String + bitsFullPath :: QualifiedPath String } -> QBitsMetadata checkStage deriving (Generic, ToJSON) @@ -619,7 +619,7 @@ data RegisterBitsDecl stage f a where qBitsMetadata :: When (stage .>= Qualified) (QBitsMetadata (stage .>= Checked)), -- | Bit declarations. -- | Optional modifier for the bits. - definedBitsModifier :: Maybe (Modifier f a), + definedBitsModifier :: Guaranteed (stage .>= Qualified) (Modifier f a), -- | Identifier for the bits. definedBitsIdent :: Identifier f a, -- | Type reference for the bits. @@ -676,7 +676,7 @@ data RegisterBitsTypeRef stage f a where -- | A direct specification of bits as an expression. RegisterBitsJustBits :: { -- | Expression for the bits. - justBitsExpr :: Expression Bits stage f a, + justBitsExpr :: ConstExpression Bits stage f a, -- | Annotation for the bits. justBitsAnnot :: a } -> diff --git a/src/Language/Fiddle/Ast/Internal/Util.hs b/src/Language/Fiddle/Ast/Internal/Util.hs index 87fca96..d2be0c3 100644 --- a/src/Language/Fiddle/Ast/Internal/Util.hs +++ b/src/Language/Fiddle/Ast/Internal/Util.hs @@ -52,7 +52,7 @@ identToString = Text.unpack . identifierName directiveToMetadata :: (Annotated (t s)) => Directed t s Identity (Commented SourceSpan) -> - NonEmpty String -> + QualifiedPath String -> Metadata directiveToMetadata (Directed directives t a) qualifiedPath = Metadata |