Support standard version 3.0.0 and drop support for older versions (#634)

See the discussion in https://github.com/dhall-lang/dhall-lang/issues/242
and the corresponding change the standard in
https://github.com/dhall-lang/dhall-lang/pull/243 for more context.

At some point we want to extend support for older versions of the standard
as far back as possible, but in order to do this correctly we need to
provide a way to systematically thread the standard version to everything
that we standardize, including:

* type-checking
* β-normalization
* α-normalization
* import resolution
* binary encoding/decoding

... and that entails a significant refactor to the API.

Given that we need to cut a new release soon, I've decided to drop support for
older releases for now.  We may eventually add them back as a matter of
principle to exercise backwards compatibility, albeit I expect that people are
unlikely to use them again once we drop support for them once.

This also changes `ProtocolVersion` to `StandardVersion` everywhere in the API
and the command line for consistency with the change to the standard, since
there is no longer a protocol version now that we use the standard version to
version everything.
This commit is contained in:
Gabriel Gonzalez 2018-10-12 14:00:10 -07:00 committed by GitHub
parent afffa17be4
commit d9713ca54c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
13 changed files with 368 additions and 368 deletions

View File

@ -4,7 +4,7 @@
module Main where
import qualified Dhall.Main as Main
import Dhall.Binary (defaultProtocolVersion)
import Dhall.Binary (defaultStandardVersion)
options :: Main.Options
options = Main.Options
@ -12,7 +12,7 @@ options = Main.Options
, Main.explain = False
, Main.plain = False
, Main.ascii = False
, Main.protocolVersion = defaultProtocolVersion
, Main.standardVersion = defaultStandardVersion
}
main :: IO ()

View File

@ -72,7 +72,7 @@ benchExprFromBytes name bytes = bench name (whnf f bytes)
term <- case Codec.Serialise.deserialiseOrFail bytes of
Left _ -> Nothing
Right term -> return term
case Dhall.Binary.decode term of
case Dhall.Binary.decodeWithVersion term of
Left _ -> Nothing
Right expression -> return expression

View File

@ -28,7 +28,7 @@ module Dhall
, sourceName
, startingContext
, normalizer
, protocolVersion
, standardVersion
, defaultInputSettings
, InputSettings
, defaultEvaluateSettings
@ -97,7 +97,7 @@ import Data.Text (Text)
import Data.Typeable (Typeable)
import Data.Vector (Vector)
import Data.Word (Word8, Word16, Word32, Word64)
import Dhall.Binary (ProtocolVersion(..))
import Dhall.Binary (StandardVersion(..))
import Dhall.Core (Expr(..), Chunks(..))
import Dhall.Import (Imported(..))
import Dhall.Parser (Src(..))
@ -201,7 +201,7 @@ sourceName k s =
data EvaluateSettings = EvaluateSettings
{ _startingContext :: Dhall.Context.Context (Expr Src X)
, _normalizer :: Dhall.Core.ReifiedNormalizer X
, _protocolVersion :: ProtocolVersion
, _standardVersion :: StandardVersion
}
-- | Default evaluation settings: no extra entries in the initial
@ -212,7 +212,7 @@ defaultEvaluateSettings :: EvaluateSettings
defaultEvaluateSettings = EvaluateSettings
{ _startingContext = Dhall.Context.empty
, _normalizer = Dhall.Core.ReifiedNormalizer (const Nothing)
, _protocolVersion = Dhall.Binary.defaultProtocolVersion
, _standardVersion = Dhall.Binary.defaultStandardVersion
}
-- | Access the starting context used for evaluation and type-checking.
@ -239,16 +239,16 @@ normalizer = evaluateSettings . l
=> LensLike' f EvaluateSettings (Dhall.Core.ReifiedNormalizer X)
l k s = fmap (\x -> s { _normalizer = x }) (k (_normalizer s))
-- | Access the protocol version used when encoding or decoding Dhall
-- expressions to and from a binary representation
-- | Access the standard version (used primarily when encoding or decoding
-- Dhall expressions to and from a binary representation)
--
-- @since 1.17
protocolVersion
standardVersion
:: (Functor f, HasEvaluateSettings s)
=> LensLike' f s ProtocolVersion
protocolVersion = evaluateSettings . l
=> LensLike' f s StandardVersion
standardVersion = evaluateSettings . l
where
l k s = fmap (\x -> s { _protocolVersion = x}) (k (_protocolVersion s))
l k s = fmap (\x -> s { _standardVersion = x}) (k (_standardVersion s))
-- | @since 1.16
class HasEvaluateSettings s where
@ -312,7 +312,7 @@ inputWithSettings settings (Type {..}) txt = do
let EvaluateSettings {..} = _evaluateSettings
let transform =
set Dhall.Import.protocolVersion _protocolVersion
set Dhall.Import.standardVersion _standardVersion
. set Dhall.Import.normalizer _normalizer
. set Dhall.Import.startingContext _startingContext
@ -405,7 +405,7 @@ inputExprWithSettings settings txt = do
let EvaluateSettings {..} = _evaluateSettings
let transform =
set Dhall.Import.protocolVersion _protocolVersion
set Dhall.Import.standardVersion _standardVersion
. set Dhall.Import.normalizer _normalizer
. set Dhall.Import.startingContext _startingContext

View File

@ -7,14 +7,14 @@
-}
module Dhall.Binary
( -- * Protocol versions
ProtocolVersion(..)
, defaultProtocolVersion
, parseProtocolVersion
( -- * Standard versions
StandardVersion(..)
, defaultStandardVersion
, parseStandardVersion
-- * Encoding and decoding
, encode
, decode
, encodeWithVersion
, decodeWithVersion
-- * Exceptions
, DecodingFailure(..)
@ -51,30 +51,28 @@ import qualified Data.Text
import qualified Dhall.Map
import qualified Options.Applicative
-- | Supported protocol version strings
data ProtocolVersion
= V_1_0
-- ^ Protocol version string "1.0"
| V_1_1
-- ^ Protocol version string "1.1"
-- | Supported version strings
data StandardVersion
= V_3_0_0
-- ^ Version "3.0.0"
defaultProtocolVersion :: ProtocolVersion
defaultProtocolVersion = V_1_1
defaultStandardVersion :: StandardVersion
defaultStandardVersion = V_3_0_0
parseProtocolVersion :: Parser ProtocolVersion
parseProtocolVersion =
Options.Applicative.option readProtocolVersion
( Options.Applicative.long "protocol-version"
<> Options.Applicative.metavar "X.Y"
<> Options.Applicative.value defaultProtocolVersion
parseStandardVersion :: Parser StandardVersion
parseStandardVersion =
Options.Applicative.option readVersion
( Options.Applicative.long "standard-version"
<> Options.Applicative.metavar "X.Y.Z"
<> Options.Applicative.help "The standard version to use"
<> Options.Applicative.value defaultStandardVersion
)
where
readProtocolVersion = do
readVersion = do
string <- Options.Applicative.str
case string :: Text of
"1.0" -> return V_1_0
"1.1" -> return V_1_1
_ -> fail "Unsupported protocol version"
"3.0.0" -> return V_3_0_0
_ -> fail "Unsupported version"
{-| Convert a function applied to multiple arguments to the base function and
the list of arguments
@ -89,250 +87,250 @@ unApply e = (baseFunction₀, diffArguments₀ [])
~(baseFunction, diffArguments) = go f
go baseFunction = (baseFunction, id)
encode_1_1 :: Expr s Import -> Term
encode_1_1 (Var (V "_" n)) =
encode :: Expr s Import -> Term
encode (Var (V "_" n)) =
TInteger n
encode_1_1 (Var (V x 0)) =
encode (Var (V x 0)) =
TString x
encode_1_1 (Var (V x n)) =
encode (Var (V x n)) =
TList [ TString x, TInteger n ]
encode_1_1 NaturalBuild =
encode NaturalBuild =
TString "Natural/build"
encode_1_1 NaturalFold =
encode NaturalFold =
TString "Natural/fold"
encode_1_1 NaturalIsZero =
encode NaturalIsZero =
TString "Natural/isZero"
encode_1_1 NaturalEven =
encode NaturalEven =
TString "Natural/even"
encode_1_1 NaturalOdd =
encode NaturalOdd =
TString "Natural/odd"
encode_1_1 NaturalToInteger =
encode NaturalToInteger =
TString "Natural/toInteger"
encode_1_1 NaturalShow =
encode NaturalShow =
TString "Natural/show"
encode_1_1 IntegerToDouble =
encode IntegerToDouble =
TString "Integer/toDouble"
encode_1_1 IntegerShow =
encode IntegerShow =
TString "Integer/show"
encode_1_1 DoubleShow =
encode DoubleShow =
TString "Double/show"
encode_1_1 ListBuild =
encode ListBuild =
TString "List/build"
encode_1_1 ListFold =
encode ListFold =
TString "List/fold"
encode_1_1 ListLength =
encode ListLength =
TString "List/length"
encode_1_1 ListHead =
encode ListHead =
TString "List/head"
encode_1_1 ListLast =
encode ListLast =
TString "List/last"
encode_1_1 ListIndexed =
encode ListIndexed =
TString "List/indexed"
encode_1_1 ListReverse =
encode ListReverse =
TString "List/reverse"
encode_1_1 OptionalFold =
encode OptionalFold =
TString "Optional/fold"
encode_1_1 OptionalBuild =
encode OptionalBuild =
TString "Optional/build"
encode_1_1 Bool =
encode Bool =
TString "Bool"
encode_1_1 Optional =
encode Optional =
TString "Optional"
encode_1_1 None =
encode None =
TString "None"
encode_1_1 Natural =
encode Natural =
TString "Natural"
encode_1_1 Integer =
encode Integer =
TString "Integer"
encode_1_1 Double =
encode Double =
TString "Double"
encode_1_1 Text =
encode Text =
TString "Text"
encode_1_1 List =
encode List =
TString "List"
encode_1_1 (Const Type) =
encode (Const Type) =
TString "Type"
encode_1_1 (Const Kind) =
encode (Const Kind) =
TString "Kind"
encode_1_1 e@(App _ _) =
TList ([ TInt 0, f ] ++ map encode_1_1 arguments)
encode e@(App _ _) =
TList ([ TInt 0, f ] ++ map encode arguments)
where
(f, arguments) = unApply e
f = encode_1_1 f
encode_1_1 (Lam "_" _A b) =
f = encode f
encode (Lam "_" _A b) =
TList [ TInt 1, _A, b ]
where
_A = encode_1_1 _A
b = encode_1_1 b
encode_1_1 (Lam x _A b) =
_A = encode _A
b = encode b
encode (Lam x _A b) =
TList [ TInt 1, TString x, _A, b ]
where
_A = encode_1_1 _A
b = encode_1_1 b
encode_1_1 (Pi "_" _A _B) =
_A = encode _A
b = encode b
encode (Pi "_" _A _B) =
TList [ TInt 2, _A, _B ]
where
_A = encode_1_1 _A
_B = encode_1_1 _B
encode_1_1 (Pi x _A _B) =
_A = encode _A
_B = encode _B
encode (Pi x _A _B) =
TList [ TInt 2, TString x, _A, _B ]
where
_A = encode_1_1 _A
_B = encode_1_1 _B
encode_1_1 (BoolOr l r) =
_A = encode _A
_B = encode _B
encode (BoolOr l r) =
TList [ TInt 3, TInt 0, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (BoolAnd l r) =
l = encode l
r = encode r
encode (BoolAnd l r) =
TList [ TInt 3, TInt 1, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (BoolEQ l r) =
l = encode l
r = encode r
encode (BoolEQ l r) =
TList [ TInt 3, TInt 2, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (BoolNE l r) =
l = encode l
r = encode r
encode (BoolNE l r) =
TList [ TInt 3, TInt 3, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (NaturalPlus l r) =
l = encode l
r = encode r
encode (NaturalPlus l r) =
TList [ TInt 3, TInt 4, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (NaturalTimes l r) =
l = encode l
r = encode r
encode (NaturalTimes l r) =
TList [ TInt 3, TInt 5, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (TextAppend l r) =
l = encode l
r = encode r
encode (TextAppend l r) =
TList [ TInt 3, TInt 6, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (ListAppend l r) =
l = encode l
r = encode r
encode (ListAppend l r) =
TList [ TInt 3, TInt 7, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (Combine l r) =
l = encode l
r = encode r
encode (Combine l r) =
TList [ TInt 3, TInt 8, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (Prefer l r) =
l = encode l
r = encode r
encode (Prefer l r) =
TList [ TInt 3, TInt 9, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (CombineTypes l r) =
l = encode l
r = encode r
encode (CombineTypes l r) =
TList [ TInt 3, TInt 10, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (ImportAlt l r) =
l = encode l
r = encode r
encode (ImportAlt l r) =
TList [ TInt 3, TInt 11, l, r ]
where
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (ListLit _T xs)
l = encode l
r = encode r
encode (ListLit _T xs)
| null xs = TList [ TInt 4, _T ]
| otherwise = TList ([ TInt 4, TNull ] ++ xs)
where
_T = case _T of
Nothing -> TNull
Just t -> encode_1_1 t
Just t -> encode t
xs = map encode_1_1 (Data.Foldable.toList xs)
encode_1_1 (OptionalLit _T Nothing) =
xs = map encode (Data.Foldable.toList xs)
encode (OptionalLit _T Nothing) =
TList [ TInt 5, _T ]
where
_T = encode_1_1 _T
encode_1_1 (OptionalLit _T (Just t)) =
_T = encode _T
encode (OptionalLit _T (Just t)) =
TList [ TInt 5, _T, t ]
where
_T = encode_1_1 _T
t = encode_1_1 t
encode_1_1 (Some t) =
_T = encode _T
t = encode t
encode (Some t) =
TList [ TInt 5, TNull, t ]
where
t = encode_1_1 t
encode_1_1 (Merge t u Nothing) =
t = encode t
encode (Merge t u Nothing) =
TList [ TInt 6, t, u ]
where
t = encode_1_1 t
u = encode_1_1 u
encode_1_1 (Merge t u (Just _T)) =
t = encode t
u = encode u
encode (Merge t u (Just _T)) =
TList [ TInt 6, t, u, _T ]
where
t = encode_1_1 t
u = encode_1_1 u
_T = encode_1_1 _T
encode_1_1 (Record xTs) =
t = encode t
u = encode u
_T = encode _T
encode (Record xTs) =
TList [ TInt 7, TMap xTs ]
where
xTs = do
(x, _T) <- Dhall.Map.toList xTs
let x = TString x
let _T = encode_1_1 _T
let _T = encode _T
return (x, _T)
encode_1_1 (RecordLit xts) =
encode (RecordLit xts) =
TList [ TInt 8, TMap xts ]
where
xts = do
(x, t) <- Dhall.Map.toList xts
let x = TString x
let t = encode_1_1 t
let t = encode t
return (x, t)
encode_1_1 (Field t x) =
encode (Field t x) =
TList [ TInt 9, t, TString x ]
where
t = encode_1_1 t
encode_1_1 (Project t xs) =
t = encode t
encode (Project t xs) =
TList ([ TInt 10, t ] ++ xs)
where
t = encode_1_1 t
t = encode t
xs = map TString (Data.Foldable.toList xs)
encode_1_1 (Union xTs) =
encode (Union xTs) =
TList [ TInt 11, TMap xTs ]
where
xTs = do
(x, _T) <- Dhall.Map.toList xTs
let x = TString x
let _T = encode_1_1 _T
let _T = encode _T
return (x, _T)
encode_1_1 (UnionLit x t yTs) =
encode (UnionLit x t yTs) =
TList [ TInt 12, TString x, t, TMap yTs ]
where
t = encode_1_1 t
t = encode t
yTs = do
(y, _T) <- Dhall.Map.toList yTs
let y = TString y
let _T = encode_1_1 _T
let _T = encode _T
return (y, _T)
encode_1_1 (Constructors u) =
encode (Constructors u) =
TList [ TInt 13, u ]
where
u = encode_1_1 u
encode_1_1 (BoolLit b) =
u = encode u
encode (BoolLit b) =
TBool b
encode_1_1 (BoolIf t l r) =
encode (BoolIf t l r) =
TList [ TInt 14, t, l, r ]
where
t = encode_1_1 t
l = encode_1_1 l
r = encode_1_1 r
encode_1_1 (NaturalLit n) =
t = encode t
l = encode l
r = encode r
encode (NaturalLit n) =
TList [ TInt 15, TInteger (fromIntegral n) ]
encode_1_1 (IntegerLit n) =
encode (IntegerLit n) =
TList [ TInt 16, TInteger n ]
encode_1_1 (DoubleLit n) =
encode (DoubleLit n) =
TList [ TInt 17, TTagged 4 (TList [ TInt exponent, TInteger mantissa ]) ]
where
normalized = Data.Scientific.normalize n
@ -340,36 +338,36 @@ encode_1_1 (DoubleLit n) =
exponent = Data.Scientific.base10Exponent normalized
mantissa = Data.Scientific.coefficient normalized
encode_1_1 (TextLit (Chunks xys z)) =
encode (TextLit (Chunks xys z)) =
TList ([ TInt 18 ] ++ xys ++ [ z ])
where
xys = do
(x, y) <- xys
let x = TString x
let y = encode_1_1 y
let y = encode y
[ x, y ]
z = TString z
encode_1_1 (Embed x) =
encode (Embed x) =
importToTerm x
encode_1_1 (Let x Nothing a b) =
encode (Let x Nothing a b) =
TList [ TInt 25, TString x, a, b ]
where
a = encode_1_1 a
b = encode_1_1 b
encode_1_1 (Let x (Just _A) a b) =
a = encode a
b = encode b
encode (Let x (Just _A) a b) =
TList [ TInt 25, TString x, _A, a, b ]
where
a = encode_1_1 a
_A = encode_1_1 _A
b = encode_1_1 b
encode_1_1 (Annot t _T) =
a = encode a
_A = encode _A
b = encode b
encode (Annot t _T) =
TList [ TInt 26, t, _T ]
where
t = encode_1_1 t
_T = encode_1_1 _T
encode_1_1 (Note _ e) =
encode_1_1 e
t = encode t
_T = encode _T
encode (Note _ e) =
encode e
importToTerm :: Import -> Term
importToTerm import_ =
@ -417,98 +415,98 @@ importToTerm import_ =
ImportHashed {..} = importHashed
decode_1_1 :: Term -> Maybe (Expr s Import)
decode_1_1 (TInt n) =
decode :: Term -> Maybe (Expr s Import)
decode (TInt n) =
return (Var (V "_" (fromIntegral n)))
decode_1_1 (TInteger n) =
decode (TInteger n) =
return (Var (V "_" n))
decode_1_1 (TString "Natural/build") =
decode (TString "Natural/build") =
return NaturalBuild
decode_1_1 (TString "Natural/fold") =
decode (TString "Natural/fold") =
return NaturalFold
decode_1_1 (TString "Natural/isZero") =
decode (TString "Natural/isZero") =
return NaturalIsZero
decode_1_1 (TString "Natural/even") =
decode (TString "Natural/even") =
return NaturalEven
decode_1_1 (TString "Natural/odd") =
decode (TString "Natural/odd") =
return NaturalOdd
decode_1_1 (TString "Natural/toInteger") =
decode (TString "Natural/toInteger") =
return NaturalToInteger
decode_1_1 (TString "Natural/show") =
decode (TString "Natural/show") =
return NaturalShow
decode_1_1 (TString "Integer/toDouble") =
decode (TString "Integer/toDouble") =
return IntegerToDouble
decode_1_1 (TString "Integer/show") =
decode (TString "Integer/show") =
return IntegerShow
decode_1_1 (TString "Double/show") =
decode (TString "Double/show") =
return DoubleShow
decode_1_1 (TString "List/build") =
decode (TString "List/build") =
return ListBuild
decode_1_1 (TString "List/fold") =
decode (TString "List/fold") =
return ListFold
decode_1_1 (TString "List/length") =
decode (TString "List/length") =
return ListLength
decode_1_1 (TString "List/head") =
decode (TString "List/head") =
return ListHead
decode_1_1 (TString "List/last") =
decode (TString "List/last") =
return ListLast
decode_1_1 (TString "List/indexed") =
decode (TString "List/indexed") =
return ListIndexed
decode_1_1 (TString "List/reverse") =
decode (TString "List/reverse") =
return ListReverse
decode_1_1 (TString "Optional/fold") =
decode (TString "Optional/fold") =
return OptionalFold
decode_1_1 (TString "Optional/build") =
decode (TString "Optional/build") =
return OptionalBuild
decode_1_1 (TString "Bool") =
decode (TString "Bool") =
return Bool
decode_1_1 (TString "Optional") =
decode (TString "Optional") =
return Optional
decode_1_1 (TString "None") =
decode (TString "None") =
return None
decode_1_1 (TString "Natural") =
decode (TString "Natural") =
return Natural
decode_1_1 (TString "Integer") =
decode (TString "Integer") =
return Integer
decode_1_1 (TString "Double") =
decode (TString "Double") =
return Double
decode_1_1 (TString "Text") =
decode (TString "Text") =
return Text
decode_1_1 (TString "List") =
decode (TString "List") =
return List
decode_1_1 (TString "Type") =
decode (TString "Type") =
return (Const Type)
decode_1_1 (TString "Kind") =
decode (TString "Kind") =
return (Const Kind)
decode_1_1 (TString x) =
decode (TString x) =
return (Var (V x 0))
decode_1_1 (TList [ TString x, TInt n ]) =
decode (TList [ TString x, TInt n ]) =
return (Var (V x (fromIntegral n)))
decode_1_1 (TList [ TString x, TInteger n ]) =
decode (TList [ TString x, TInteger n ]) =
return (Var (V x n))
decode_1_1 (TList (TInt 0 : f : xs)) = do
f <- decode_1_1 f
xs <- traverse decode_1_1 xs
decode (TList (TInt 0 : f : xs)) = do
f <- decode f
xs <- traverse decode xs
return (foldl App f xs)
decode_1_1 (TList [ TInt 1, _A, b ]) = do
_A <- decode_1_1 _A
b <- decode_1_1 b
decode (TList [ TInt 1, _A, b ]) = do
_A <- decode _A
b <- decode b
return (Lam "_" _A b)
decode_1_1 (TList [ TInt 1, TString x, _A, b ]) = do
_A <- decode_1_1 _A
b <- decode_1_1 b
decode (TList [ TInt 1, TString x, _A, b ]) = do
_A <- decode _A
b <- decode b
return (Lam x _A b)
decode_1_1 (TList [ TInt 2, _A, _B ]) = do
_A <- decode_1_1 _A
_B <- decode_1_1 _B
decode (TList [ TInt 2, _A, _B ]) = do
_A <- decode _A
_B <- decode _B
return (Pi "_" _A _B)
decode_1_1 (TList [ TInt 2, TString x, _A, _B ]) = do
_A <- decode_1_1 _A
_B <- decode_1_1 _B
decode (TList [ TInt 2, TString x, _A, _B ]) = do
_A <- decode _A
_B <- decode _B
return (Pi x _A _B)
decode_1_1 (TList [ TInt 3, TInt n, l, r ]) = do
l <- decode_1_1 l
r <- decode_1_1 r
decode (TList [ TInt 3, TInt n, l, r ]) = do
l <- decode l
r <- decode r
op <- case n of
0 -> return BoolOr
1 -> return BoolAnd
@ -524,34 +522,34 @@ decode_1_1 (TList [ TInt 3, TInt n, l₁, r₁ ]) = do
11 -> return ImportAlt
_ -> empty
return (op l r)
decode_1_1 (TList [ TInt 4, _T ]) = do
_T <- decode_1_1 _T
decode (TList [ TInt 4, _T ]) = do
_T <- decode _T
return (ListLit (Just _T) empty)
decode_1_1 (TList (TInt 4 : TNull : xs )) = do
xs <- traverse decode_1_1 xs
decode (TList (TInt 4 : TNull : xs )) = do
xs <- traverse decode xs
return (ListLit Nothing (Data.Sequence.fromList xs))
decode_1_1 (TList [ TInt 5, _T ]) = do
_T <- decode_1_1 _T
decode (TList [ TInt 5, _T ]) = do
_T <- decode _T
return (OptionalLit _T Nothing)
decode_1_1 (TList [ TInt 5, TNull, t ]) = do
t <- decode_1_1 t
decode (TList [ TInt 5, TNull, t ]) = do
t <- decode t
return (Some t)
decode_1_1 (TList [ TInt 5, _T, t ]) = do
_T <- decode_1_1 _T
t <- decode_1_1 t
decode (TList [ TInt 5, _T, t ]) = do
_T <- decode _T
t <- decode t
return (OptionalLit _T (Just t))
decode_1_1 (TList [ TInt 6, t, u ]) = do
t <- decode_1_1 t
u <- decode_1_1 u
decode (TList [ TInt 6, t, u ]) = do
t <- decode t
u <- decode u
return (Merge t u Nothing)
decode_1_1 (TList [ TInt 6, t, u, _T ]) = do
t <- decode_1_1 t
u <- decode_1_1 u
_T <- decode_1_1 _T
decode (TList [ TInt 6, t, u, _T ]) = do
t <- decode t
u <- decode u
_T <- decode _T
return (Merge t u (Just _T))
decode_1_1 (TList [ TInt 7, TMap xTs ]) = do
decode (TList [ TInt 7, TMap xTs ]) = do
let process (TString x, _T) = do
_T <- decode_1_1 _T
_T <- decode _T
return (x, _T)
process _ =
@ -560,9 +558,9 @@ decode_1_1 (TList [ TInt 7, TMap xTs₁ ]) = do
xTs <- traverse process xTs
return (Record (Dhall.Map.fromList xTs))
decode_1_1 (TList [ TInt 8, TMap xts ]) = do
decode (TList [ TInt 8, TMap xts ]) = do
let process (TString x, t) = do
t <- decode_1_1 t
t <- decode t
return (x, t)
process _ =
@ -571,12 +569,12 @@ decode_1_1 (TList [ TInt 8, TMap xts₁ ]) = do
xts <- traverse process xts
return (RecordLit (Dhall.Map.fromList xts))
decode_1_1 (TList [ TInt 9, t, TString x ]) = do
t <- decode_1_1 t
decode (TList [ TInt 9, t, TString x ]) = do
t <- decode t
return (Field t x)
decode_1_1 (TList (TInt 10 : t : xs)) = do
t <- decode_1_1 t
decode (TList (TInt 10 : t : xs)) = do
t <- decode t
let process (TString x) = return x
process _ = empty
@ -584,9 +582,9 @@ decode_1_1 (TList (TInt 10 : t₁ : xs₁)) = do
xs <- traverse process xs
return (Project t (Data.Set.fromList xs))
decode_1_1 (TList [ TInt 11, TMap xTs ]) = do
decode (TList [ TInt 11, TMap xTs ]) = do
let process (TString x, _T) = do
_T <- decode_1_1 _T
_T <- decode _T
return (x, _T)
process _ =
@ -595,11 +593,11 @@ decode_1_1 (TList [ TInt 11, TMap xTs₁ ]) = do
xTs <- traverse process xTs
return (Union (Dhall.Map.fromList xTs))
decode_1_1 (TList [ TInt 12, TString x, t, TMap yTs ]) = do
t <- decode_1_1 t
decode (TList [ TInt 12, TString x, t, TMap yTs ]) = do
t <- decode t
let process (TString y, _T) = do
_T <- decode_1_1 _T
_T <- decode _T
return (y, _T)
process _ =
@ -608,33 +606,33 @@ decode_1_1 (TList [ TInt 12, TString x, t₁, TMap yTs₁ ]) = do
yTs <- traverse process yTs
return (UnionLit x t (Dhall.Map.fromList yTs))
decode_1_1 (TList [ TInt 13, u ]) = do
u <- decode_1_1 u
decode (TList [ TInt 13, u ]) = do
u <- decode u
return (Constructors u)
decode_1_1 (TBool b) = do
decode (TBool b) = do
return (BoolLit b)
decode_1_1 (TList [ TInt 14, t, l, r ]) = do
t <- decode_1_1 t
l <- decode_1_1 l
r <- decode_1_1 r
decode (TList [ TInt 14, t, l, r ]) = do
t <- decode t
l <- decode l
r <- decode r
return (BoolIf t l r)
decode_1_1 (TList [ TInt 15, TInt n ]) = do
decode (TList [ TInt 15, TInt n ]) = do
return (NaturalLit (fromIntegral n))
decode_1_1 (TList [ TInt 15, TInteger n ]) = do
decode (TList [ TInt 15, TInteger n ]) = do
return (NaturalLit (fromInteger n))
decode_1_1 (TList [ TInt 16, TInt n ]) = do
decode (TList [ TInt 16, TInt n ]) = do
return (IntegerLit (fromIntegral n))
decode_1_1 (TList [ TInt 16, TInteger n ]) = do
decode (TList [ TInt 16, TInteger n ]) = do
return (IntegerLit n)
decode_1_1 (TList [ TInt 17, TTagged 4 (TList [ TInt exponent, TInteger mantissa ]) ]) = do
decode (TList [ TInt 17, TTagged 4 (TList [ TInt exponent, TInteger mantissa ]) ]) = do
return (DoubleLit (Data.Scientific.scientific mantissa exponent))
decode_1_1 (TList [ TInt 17, TTagged 4 (TList [ TInt exponent, TInt mantissa ]) ]) = do
decode (TList [ TInt 17, TTagged 4 (TList [ TInt exponent, TInt mantissa ]) ]) = do
return (DoubleLit (Data.Scientific.scientific (fromIntegral mantissa) exponent))
decode_1_1 (TList (TInt 18 : xs)) = do
decode (TList (TInt 18 : xs)) = do
let process (TString x : y : zs) = do
y <- decode_1_1 y
y <- decode y
~(xys, z) <- process zs
@ -647,7 +645,7 @@ decode_1_1 (TList (TInt 18 : xs)) = do
(xys, z) <- process xs
return (TextLit (Chunks xys z))
decode_1_1 (TList (TInt 24 : TInt n : xs)) = do
decode (TList (TInt 24 : TInt n : xs)) = do
let remote scheme = do
let process [ TString file, q, f ] = do
query <- case q of
@ -720,57 +718,55 @@ decode_1_1 (TList (TInt 24 : TInt n : xs)) = do
let importHashed = ImportHashed {..}
let importMode = Code
return (Embed (Import {..}))
decode_1_1 (TList [ TInt 25, TString x, a, b ]) = do
a <- decode_1_1 a
b <- decode_1_1 b
decode (TList [ TInt 25, TString x, a, b ]) = do
a <- decode a
b <- decode b
return (Let x Nothing a b)
decode_1_1 (TList [ TInt 25, TString x, _A, a, b ]) = do
_A <- decode_1_1 _A
a <- decode_1_1 a
b <- decode_1_1 b
decode (TList [ TInt 25, TString x, _A, a, b ]) = do
_A <- decode _A
a <- decode a
b <- decode b
return (Let x (Just _A) a b)
decode_1_1 (TList [ TInt 26, t, _T ]) = do
t <- decode_1_1 t
_T <- decode_1_1 _T
decode (TList [ TInt 26, t, _T ]) = do
t <- decode t
_T <- decode _T
return (Annot t _T)
decode_1_1 _ =
decode _ =
empty
{-| Decode a Dhall expression
This auto-detects whiich protocol version to decode based on the included
protocol version string in the decoded expression
This auto-detects which standard version to decode based on the included
standard version string in the decoded expression
-}
decode :: Term -> Either DecodingFailure (Expr s Import)
decode term = do
decodeWithVersion :: Term -> Either DecodingFailure (Expr s Import)
decodeWithVersion term = do
(version, subTerm) <- case term of
TList [ TString version, subTerm ] ->
return (version, subTerm)
_ ->
fail ("Cannot decode the version from this decoded CBOR expression: " <> show term)
maybeExpression <- case version of
"1.0" -> do
return (decode_1_1 subTerm)
"1.1" -> do
return (decode_1_1 subTerm)
case version of
"3.0.0" -> do
return ()
_ -> do
fail ("This decoded version is not supported: " <> Data.Text.unpack version)
case maybeExpression of
case decode subTerm of
Nothing ->
fail ("This decoded CBOR expression does not represent a valid Dhall expression: " <> show subTerm)
Just expression ->
return expression
-- | Encode a Dhall expression using the specified `ProtocolVersion`
encode :: ProtocolVersion -> Expr s Import -> Term
encode V_1_0 expression = TList [ TString "1.0", encode_1_1 expression ]
encode V_1_1 expression = TList [ TString "1.1", encode_1_1 expression ]
-- | Encode a Dhall expression using the specified `Version`
encodeWithVersion :: StandardVersion -> Expr s Import -> Term
encodeWithVersion V_3_0_0 expression =
TList [ TString "3.0.0", encode expression ]
data DecodingFailure
= CannotDecodeProtocolVersionString Term
| UnsupportedProtocolVersionString Text
= CannotDecodeVersionString Term
| UnsupportedVersionString Text
| CBORIsNotDhall Term
deriving (Eq)
@ -780,21 +776,21 @@ _ERROR :: String
_ERROR = "\ESC[1;31mError\ESC[0m"
instance Show DecodingFailure where
show (CannotDecodeProtocolVersionString term) =
show (CannotDecodeVersionString term) =
_ERROR <> ": Cannot decode version string\n"
<> "\n"
<> "This CBOR expression does not contain a protocol version string in any\n"
<> "This CBOR expression does not contain a version string in any\n"
<> "recognizable format\n"
<> "\n"
<> "" <> show term <> "\n"
show (UnsupportedProtocolVersionString version) =
show (UnsupportedVersionString version) =
_ERROR <> ": Unsupported version string\n"
<> "\n"
<> "The encoded Dhall expression was tagged with a protocol version string of:\n"
<> "The encoded Dhall expression was tagged with a version string of:\n"
<> "\n"
<> "" <> show version <> "\n"
<> "\n"
<> "... but this implementation cannot decode that protocol version\n"
<> "... but this implementation cannot decode that version\n"
<> "\n"
<> "Some common reasons why you might get this error:\n"
<> "\n"

View File

@ -11,9 +11,9 @@ module Dhall.Freeze
import Data.Monoid ((<>))
import Data.Maybe (fromMaybe)
import Data.Text
import Dhall.Binary (ProtocolVersion(..))
import Dhall.Binary (StandardVersion(..))
import Dhall.Core (Expr(..), Import(..), ImportHashed(..))
import Dhall.Import (protocolVersion)
import Dhall.Import (standardVersion)
import Dhall.Parser (exprAndHeaderFromText, Src)
import Dhall.Pretty (annToAnsiStyle, layoutOpts)
import Lens.Family (set)
@ -34,11 +34,11 @@ import qualified System.IO
hashImport
:: FilePath
-- ^ Current working directory
-> ProtocolVersion
-> StandardVersion
-> Import
-> IO Import
hashImport directory _protocolVersion import_ = do
let status = set protocolVersion _protocolVersion (Dhall.Import.emptyStatus directory)
hashImport directory _standardVersion import_ = do
let status = set standardVersion _standardVersion (Dhall.Import.emptyStatus directory)
expression <- State.evalStateT (Dhall.Import.loadWith (Embed import_)) status
@ -50,7 +50,7 @@ hashImport directory _protocolVersion import_ = do
Dhall.Core.alphaNormalize (Dhall.Core.normalize expression)
let expressionHash =
Just (Dhall.Import.hashExpression _protocolVersion normalizedExpression)
Just (Dhall.Import.hashExpression _standardVersion normalizedExpression)
let newImportHashed = (importHashed import_) { hash = expressionHash }
@ -90,9 +90,9 @@ freeze
:: Maybe FilePath
-- ^ Modify file in-place if present, otherwise read from @stdin@ and write
-- to @stdout@
-> ProtocolVersion
-> StandardVersion
-> IO ()
freeze inplace _protocolVersion = do
freeze inplace _standardVersion = do
(text, directory) <- case inplace of
Nothing -> do
text <- Data.Text.IO.getContents
@ -105,7 +105,7 @@ freeze inplace _protocolVersion = do
return (text, System.FilePath.takeDirectory file)
(header, parsedExpression) <- parseExpr srcInfo text
frozenExpression <- traverse (hashImport directory _protocolVersion) parsedExpression
frozenExpression <- traverse (hashImport directory _standardVersion) parsedExpression
writeExpr inplace (header, frozenExpression)
where
srcInfo = fromMaybe "(stdin)" inplace

View File

@ -7,9 +7,9 @@ module Dhall.Hash
hash
) where
import Dhall.Binary (ProtocolVersion)
import Dhall.Binary (StandardVersion)
import Dhall.Parser (exprFromText)
import Dhall.Import (hashExpressionToCode, protocolVersion)
import Dhall.Import (hashExpressionToCode, standardVersion)
import Lens.Family (set)
import qualified Control.Monad.Trans.State.Strict as State
@ -20,8 +20,8 @@ import qualified Dhall.TypeCheck
import qualified Data.Text.IO
-- | Implementation of the @dhall hash@ subcommand
hash :: ProtocolVersion -> IO ()
hash _protocolVersion = do
hash :: StandardVersion -> IO ()
hash _standardVersion = do
inText <- Data.Text.IO.getContents
parsedExpression <- case exprFromText "(stdin)" inText of
@ -29,7 +29,7 @@ hash _protocolVersion = do
Right parsedExpression -> return parsedExpression
let status =
set protocolVersion _protocolVersion (Dhall.Import.emptyStatus ".")
set standardVersion _standardVersion (Dhall.Import.emptyStatus ".")
resolvedExpression <- State.evalStateT (Dhall.Import.loadWith parsedExpression) status
@ -41,4 +41,4 @@ hash _protocolVersion = do
Dhall.Core.alphaNormalize (Dhall.Core.normalize resolvedExpression)
Data.Text.IO.putStrLn
(hashExpressionToCode _protocolVersion normalizedExpression)
(hashExpressionToCode _standardVersion normalizedExpression)

View File

@ -112,7 +112,7 @@ module Dhall.Import (
, stack
, cache
, manager
, protocolVersion
, standardVersion
, normalizer
, startingContext
, resolver
@ -145,7 +145,7 @@ import Data.Traversable (traverse)
#endif
import Data.Typeable (Typeable)
import System.FilePath ((</>))
import Dhall.Binary (ProtocolVersion(..))
import Dhall.Binary (StandardVersion(..))
import Dhall.Core
( Expr(..)
, Chunks(..)
@ -483,7 +483,7 @@ exprFromImport here@(Import {..}) = do
term <- throws (Codec.Serialise.deserialiseOrFail bytesLazy)
throws (Dhall.Binary.decode term)
throws (Dhall.Binary.decodeWithVersion term)
case result of
Just expression -> return expression
@ -520,7 +520,7 @@ exprToImport here expression = do
expression
)
let bytes = encodeExpression _protocolVersion normalizedExpression
let bytes = encodeExpression _standardVersion normalizedExpression
let actualHash = Crypto.Hash.hash bytes
@ -782,7 +782,7 @@ loadWith expr₀ = case expr₀ of
return ()
Just expectedHash -> do
let actualHash =
hashExpression _protocolVersion (Dhall.Core.alphaNormalize expr)
hashExpression _standardVersion (Dhall.Core.alphaNormalize expr)
if expectedHash == actualHash
then return ()
@ -865,23 +865,26 @@ load :: Expr Src Import -> IO (Expr Src X)
load expression = State.evalStateT (loadWith expression) (emptyStatus ".")
encodeExpression
:: forall s . ProtocolVersion -> Expr s X -> Data.ByteString.ByteString
encodeExpression _protocolVersion expression = bytesStrict
:: forall s . StandardVersion -> Expr s X -> Data.ByteString.ByteString
encodeExpression _standardVersion expression = bytesStrict
where
intermediateExpression :: Expr s Import
intermediateExpression = fmap absurd expression
term :: Term
term = Dhall.Binary.encode _protocolVersion intermediateExpression
term =
Dhall.Binary.encodeWithVersion
_standardVersion
intermediateExpression
bytesLazy = Codec.Serialise.serialise term
bytesStrict = Data.ByteString.Lazy.toStrict bytesLazy
-- | Hash a fully resolved expression
hashExpression :: ProtocolVersion -> Expr s X -> (Crypto.Hash.Digest SHA256)
hashExpression _protocolVersion expression =
Crypto.Hash.hash (encodeExpression _protocolVersion expression)
hashExpression :: StandardVersion -> Expr s X -> (Crypto.Hash.Digest SHA256)
hashExpression _standardVersion expression =
Crypto.Hash.hash (encodeExpression _standardVersion expression)
{-| Convenience utility to hash a fully resolved expression and return the
base-16 encoded hash with the @sha256:@ prefix
@ -889,9 +892,9 @@ hashExpression _protocolVersion expression =
In other words, the output of this function can be pasted into Dhall
source code to add an integrity check to an import
-}
hashExpressionToCode :: ProtocolVersion -> Expr s X -> Text
hashExpressionToCode _protocolVersion expr =
"sha256:" <> Text.pack (show (hashExpression _protocolVersion expr))
hashExpressionToCode :: StandardVersion -> Expr s X -> Text
hashExpressionToCode _standardVersion expr =
"sha256:" <> Text.pack (show (hashExpression _standardVersion expr))
-- | A call to `assertNoImports` failed because there was at least one import
data ImportResolutionDisabled = ImportResolutionDisabled deriving (Exception)

View File

@ -10,7 +10,7 @@ import Data.Dynamic
import Data.List.NonEmpty (NonEmpty)
import Data.Map (Map)
import Data.Semigroup ((<>))
import Dhall.Binary (ProtocolVersion(..))
import Dhall.Binary (StandardVersion(..))
import Dhall.Context (Context)
import Dhall.Core
( Directory (..)
@ -46,7 +46,7 @@ data Status m = Status
, _manager :: Maybe Dynamic
-- ^ Cache for the HTTP `Manager` so that we only acquire it once
, _protocolVersion :: ProtocolVersion
, _standardVersion :: StandardVersion
, _normalizer :: ReifiedNormalizer X
@ -71,7 +71,7 @@ emptyStatusWith _resolver _cacher rootDirectory = Status {..}
_manager = Nothing
_protocolVersion = Dhall.Binary.defaultProtocolVersion
_standardVersion = Dhall.Binary.defaultStandardVersion
_normalizer = ReifiedNormalizer (const Nothing)
@ -103,9 +103,9 @@ cache k s = fmap (\x -> s { _cache = x }) (k (_cache s))
manager :: Functor f => LensLike' f (Status m) (Maybe Dynamic)
manager k s = fmap (\x -> s { _manager = x }) (k (_manager s))
protocolVersion :: Functor f => LensLike' f (Status m) ProtocolVersion
protocolVersion k s =
fmap (\x -> s { _protocolVersion = x }) (k (_protocolVersion s))
standardVersion :: Functor f => LensLike' f (Status m) StandardVersion
standardVersion k s =
fmap (\x -> s { _standardVersion = x }) (k (_standardVersion s))
normalizer :: Functor f => LensLike' f (Status m) (ReifiedNormalizer X)
normalizer k s = fmap (\x -> s { _normalizer = x }) (k (_normalizer s))

View File

@ -24,7 +24,7 @@ import Data.Monoid ((<>))
import Data.Text (Text)
import Data.Text.Prettyprint.Doc (Doc, Pretty)
import Data.Version (showVersion)
import Dhall.Binary (ProtocolVersion)
import Dhall.Binary (StandardVersion)
import Dhall.Core (Expr(..), Import)
import Dhall.Import (Imported(..))
import Dhall.Parser (Src)
@ -68,7 +68,7 @@ data Options = Options
, explain :: Bool
, plain :: Bool
, ascii :: Bool
, protocolVersion :: ProtocolVersion
, standardVersion :: StandardVersion
}
-- | The subcommands for the @dhall@ executable
@ -95,7 +95,7 @@ parseOptions =
<*> switch "explain" "Explain error messages in more detail"
<*> switch "plain" "Disable syntax highlighting"
<*> switch "ascii" "Format code using only ASCII syntax"
<*> Dhall.Binary.parseProtocolVersion
<*> Dhall.Binary.parseStandardVersion
where
switch name description =
Options.Applicative.switch
@ -213,7 +213,7 @@ command (Options {..}) = do
GHC.IO.Encoding.setLocaleEncoding System.IO.utf8
let status =
set Dhall.Import.protocolVersion protocolVersion (Dhall.Import.emptyStatus ".")
set Dhall.Import.standardVersion standardVersion (Dhall.Import.emptyStatus ".")
let handle =
@ -309,7 +309,7 @@ command (Options {..}) = do
render System.IO.stdout (Dhall.Core.normalize inferredType)
Repl -> do
Dhall.Repl.repl characterSet explain protocolVersion
Dhall.Repl.repl characterSet explain standardVersion
Diff {..} -> do
expression1 <- Dhall.inputExpr expr1
@ -324,10 +324,10 @@ command (Options {..}) = do
Dhall.Format.format characterSet inplace
Freeze {..} -> do
Dhall.Freeze.freeze inplace protocolVersion
Dhall.Freeze.freeze inplace standardVersion
Hash -> do
Dhall.Hash.hash protocolVersion
Dhall.Hash.hash standardVersion
Lint {..} -> do
case inplace of
@ -359,7 +359,8 @@ command (Options {..}) = do
Encode -> do
expression <- getExpression
let term = Dhall.Binary.encode protocolVersion expression
let term =
Dhall.Binary.encodeWithVersion standardVersion expression
let bytes = Codec.Serialise.serialise term
@ -370,7 +371,7 @@ command (Options {..}) = do
term <- throws (Codec.Serialise.deserialiseOrFail bytes)
expression <- throws (Dhall.Binary.decode term)
expression <- throws (Dhall.Binary.decodeWithVersion term)
let doc = Dhall.Pretty.prettyCharacterSet characterSet expression

View File

@ -14,8 +14,8 @@ import Control.Monad.IO.Class ( MonadIO, liftIO )
import Control.Monad.State.Class ( MonadState, get, modify )
import Control.Monad.State.Strict ( evalStateT )
import Data.List ( foldl' )
import Dhall.Binary (ProtocolVersion(..))
import Dhall.Import (protocolVersion)
import Dhall.Binary (StandardVersion(..))
import Dhall.Import (standardVersion)
import Dhall.Pretty (CharacterSet(..))
import Lens.Family (set)
@ -38,8 +38,8 @@ import qualified System.Console.Repline as Repline
import qualified System.IO
-- | Implementation of the @dhall repl@ subcommand
repl :: CharacterSet -> Bool -> ProtocolVersion -> IO ()
repl characterSet explain _protocolVersion =
repl :: CharacterSet -> Bool -> StandardVersion -> IO ()
repl characterSet explain _standardVersion =
if explain then Dhall.detailed io else io
where
io =
@ -52,7 +52,7 @@ repl characterSet explain _protocolVersion =
( Repline.Word completer )
greeter
)
(emptyEnv { characterSet, explain, _protocolVersion })
(emptyEnv { characterSet, explain, _standardVersion })
data Env = Env
@ -60,7 +60,7 @@ data Env = Env
, envIt :: Maybe Binding
, explain :: Bool
, characterSet :: CharacterSet
, _protocolVersion :: ProtocolVersion
, _standardVersion :: StandardVersion
}
@ -70,7 +70,7 @@ emptyEnv =
{ envBindings = Dhall.Context.empty
, envIt = Nothing
, explain = False
, _protocolVersion = Dhall.Binary.defaultProtocolVersion
, _standardVersion = Dhall.Binary.defaultStandardVersion
, characterSet = Unicode
}
@ -107,7 +107,7 @@ parseAndLoad src = do
return a
let status =
set protocolVersion (_protocolVersion env) (Dhall.emptyStatus ".")
set standardVersion (_standardVersion env) (Dhall.emptyStatus ".")
liftIO ( State.evalStateT (Dhall.loadWith parsed) status )

View File

@ -313,10 +313,10 @@ binaryRoundtrip :: Expr () Import -> Property
binaryRoundtrip expression =
wrap
(fmap
Dhall.Binary.decode
Dhall.Binary.decodeWithVersion
(Codec.Serialise.deserialiseOrFail
(Codec.Serialise.serialise
(Dhall.Binary.encode Dhall.Binary.defaultProtocolVersion expression)
(Dhall.Binary.encodeWithVersion Dhall.Binary.defaultStandardVersion expression)
)
)
)

View File

@ -1,5 +1,5 @@
{ example0 =
./fieldOrderA.dhall sha256:61e722187593ef313ba11d64a0c4a07126bcdac8d662b3329aeeaad5f2fe223b
./fieldOrderA.dhall sha256:72791c3846cef2ec49baabe6a5d38ca25301ed30b45754dfa1c6b06bab8faaf6
, example1 =
./fieldOrderB.dhall sha256:61e722187593ef313ba11d64a0c4a07126bcdac8d662b3329aeeaad5f2fe223b
}
./fieldOrderB.dhall sha256:72791c3846cef2ec49baabe6a5d38ca25301ed30b45754dfa1c6b06bab8faaf6
}

View File

@ -1 +1 @@
./issue553A.dhall sha256:25bf5a9d0b8c7024964715e9a9b0aff666088c922b79fea95c5e2d5565d6398f
./issue553A.dhall sha256:ef4cce5b6c440b2409f9ba86e48fb788b7ccb757569a713492654f23209cb19b