-
Notifications
You must be signed in to change notification settings - Fork 139
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow local logical aliases (defines) #2463
base: develop
Are you sure you want to change the base?
Changes from 12 commits
06f5a41
30fd1b8
a92858b
2d6cb46
2a5a8de
760a520
0f8f117
0b86503
9b24f50
9971f17
7f1c0f0
8ff6c1c
f6e6eca
8960f82
f502dd0
f84a7e8
b008f84
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,27 @@ module Language.Haskell.Liquid.GHC.CoreToLogic where | |
|
||
coreToLogic :: String | ||
coreToLogic = unlines | ||
[ "define Data.Set.Base.singleton x = (Set_sng x)" | ||
[ "define GHC.Types.True = (true)" | ||
, "define GHC.Internal.Real.div x y = (x / y)" | ||
clayrat marked this conversation as resolved.
Show resolved
Hide resolved
|
||
, "define GHC.Internal.Real.mod x y = (x mod y)" | ||
, "define GHC.Internal.Real.fromIntegral x = (x)" | ||
|
||
, "define GHC.Classes.not x = (~ x)" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe this can go in |
||
, "define GHC.Internal.Base.$ f x = (f x)" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe this can be migrated to |
||
, "" | ||
, "define GHC.CString.unpackCString# x = x" | ||
clayrat marked this conversation as resolved.
Show resolved
Hide resolved
|
||
, "" | ||
, "define Main.mempty = (mempty)" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Does this one have any effect on tests? |
||
, "" | ||
, "define Control.Parallel.Strategies.withStrategy s x = (x)" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Could it be migrated to |
||
, "" | ||
, "define Language.Haskell.Liquid.Equational.eq x y = (y)" | ||
|
||
, "define Language.Haskell.Liquid.ProofCombinators.cast x y = (y)" | ||
, "define Liquid.ProofCombinators.cast x y = (y)" | ||
, "define ProofCombinators.cast x y = (y)" | ||
, "" | ||
, "define Data.Set.Base.singleton x = (Set_sng x)" | ||
clayrat marked this conversation as resolved.
Show resolved
Hide resolved
|
||
, "define Data.Set.Base.union x y = (Set_cup x y)" | ||
, "define Data.Set.Base.intersection x y = (Set_cap x y)" | ||
, "define Data.Set.Base.difference x y = (Set_dif x y)" | ||
|
@@ -21,33 +41,4 @@ coreToLogic = unlines | |
, "define Data.Set.Internal.member x xs = (Set_mem x xs)" | ||
, "define Data.Set.Internal.isSubsetOf x y = (Set_sub x y)" | ||
, "define Data.Set.Internal.fromList xs = (Data.Set_LHAssumptions.listElts xs)" | ||
, "" | ||
, "define GHC.Internal.Real.fromIntegral x = (x)" | ||
, "" | ||
, "define GHC.Types.True = (true)" | ||
, "define GHC.Internal.Real.div x y = (x / y)" | ||
, "define GHC.Internal.Real.mod x y = (x mod y)" | ||
, "define GHC.Internal.Num.fromInteger x = (x)" | ||
, "define GHC.Num.Integer.IS x = (x)" | ||
, "define GHC.Classes.not x = (~ x)" | ||
, "define GHC.Internal.Base.$ f x = (f x)" | ||
, "" | ||
, "define Language.Haskell.Liquid.Bag.get k b = (Bag_count b k)" | ||
, "define Language.Haskell.Liquid.Bag.put k b = (Bag_union b (Bag_sng k 1))" | ||
, "define Language.Haskell.Liquid.Bag.union a b = (Bag_union a b)" | ||
, "define Language.Haskell.Liquid.Bag.unionMax a b = (Bag_union_max a b)" | ||
, "define Language.Haskell.Liquid.Bag.interMin a b = (Bag_inter_min a b)" | ||
, "define Language.Haskell.Liquid.Bag.sub a b = (Bag_sub a b)" | ||
, "define Language.Haskell.Liquid.Bag.empty = (Bag_empty 0)" | ||
, "" | ||
, "define Main.mempty = (mempty)" | ||
, "define Language.Haskell.Liquid.ProofCombinators.cast x y = (y)" | ||
, "define Language.Haskell.Liquid.ProofCombinators.withProof x y = (x)" | ||
, "define ProofCombinators.cast x y = (y)" | ||
, "define Liquid.ProofCombinators.cast x y = (y)" | ||
, "define Control.Parallel.Strategies.withStrategy s x = (x)" | ||
, "" | ||
, "define Language.Haskell.Liquid.Equational.eq x y = (y)" | ||
, "" | ||
, "define GHC.CString.unpackCString# x = x" | ||
] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To migrate to
src/GHC/Types_LHAssumptions.hs
(?)