diff options
Diffstat (limited to 'src/Language/Fiddle/Internal/UnitInterface.hs')
-rw-r--r-- | src/Language/Fiddle/Internal/UnitInterface.hs | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/Language/Fiddle/Internal/UnitInterface.hs b/src/Language/Fiddle/Internal/UnitInterface.hs index c5cbc2c..2a538eb 100644 --- a/src/Language/Fiddle/Internal/UnitInterface.hs +++ b/src/Language/Fiddle/Internal/UnitInterface.hs @@ -8,6 +8,7 @@ import GHC.Generics import Language.Fiddle.Internal.Scopes (Scope) import qualified Language.Fiddle.Internal.Scopes as Scopes import Language.Fiddle.Types (SourceSpan) +import Language.Fiddle.Internal.UnitNumbers data InternalDirectiveExpression = InternalDirectiveExpressionNumber String @@ -93,7 +94,7 @@ data ExportedLocationDecl where { -- | Metadata associated with the location. exportedLocationMetadata :: Metadata, -- | The value of the location as an integer. - exportedLocationValue :: Integer + exportedLocationValue :: N Address } -> ExportedLocationDecl deriving (Show, Eq, Ord, Generic, FromJSON, ToJSON) @@ -105,7 +106,7 @@ data ExportedBitsDecl where { -- | Metadata associated with the bits declaration. exportedBitsDeclMetadata :: Metadata, -- | The size of the bits in this declaration. - exportedBitsDeclSizeBits :: Word32 + exportedBitsDeclSizeBits :: N Bits } -> ExportedBitsDecl deriving (Show, Eq, Ord, Generic, FromJSON, ToJSON) @@ -117,7 +118,7 @@ data ExportedTypeDecl where { -- | Metadata associated with the type declaration. exportedTypeDeclMetadata :: Metadata, -- | The size of the type in bytes. - exportedTypeDeclSizeBytes :: Word32 + exportedTypeDeclSizeBytes :: N Bytes } -> ExportedTypeDecl deriving (Show, Eq, Ord, Generic, FromJSON, ToJSON) @@ -127,7 +128,7 @@ data ReferencedObjectType where {objectTypeReference :: String} -> ReferencedObjectType ArrayObjectType :: { arrayObjectTypeType :: ReferencedObjectType, - arryObjecttTypeNumber :: Word32 + arryObjecttTypeNumber :: N Unitless } -> ReferencedObjectType deriving (Show, Eq, Ord, Generic, FromJSON, ToJSON) @@ -139,7 +140,7 @@ data ExportedObjectDecl where { -- | Metadata associated with the object declaration. exportedObjectDeclMetadata :: Metadata, -- | The memory location of the object. - exportedObjectDeclLocation :: Integer, + exportedObjectDeclLocation :: N Address, -- | The type of the object as a string. exportedObjectDeclType :: ReferencedObjectType } -> |