Skip to content

Commit 9f7aaa6

Browse files
authored
Add support for nothunks == 0.3.* (#7428)
Support was added with CPP to extent the existing range of support.
1 parent 14c06ac commit 9f7aaa6

File tree

5 files changed

+87
-3
lines changed

5 files changed

+87
-3
lines changed
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
<!--
2+
A new scriv changelog fragment.
3+
4+
Uncomment the section that is right (remove the HTML comment wrapper).
5+
For top level release notes, leave all the headers commented out.
6+
-->
7+
8+
<!--
9+
### Removed
10+
11+
- A bullet item for the Removed category.
12+
13+
-->
14+
<!--
15+
### Added
16+
17+
- A bullet item for the Added category.
18+
19+
-->
20+
### Changed
21+
22+
- Add support for nothunks == 0.3.*
23+
24+
<!--
25+
### Deprecated
26+
27+
- A bullet item for the Deprecated category.
28+
29+
-->
30+
<!--
31+
### Fixed
32+
33+
- A bullet item for the Fixed category.
34+
35+
-->
36+
<!--
37+
### Security
38+
39+
- A bullet item for the Security category.
40+
41+
-->

plutus-core/plutus-core.cabal

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,7 @@ library
331331
, monoidal-containers
332332
, mtl
333333
, multiset
334-
, nothunks ^>=0.2
334+
, nothunks >=0.2 && <0.4
335335
, parser-combinators >=0.4.0
336336
, plutus-core:flat
337337
, prettyprinter >=1.1.0.1

plutus-core/plutus-core/src/PlutusCore/Builtin/Runtime.hs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,9 @@ instance NoThunks (BuiltinRuntime val) where
3939
-- Unreachable, because we don't allow nullary builtins and the 'BuiltinArrow' case only
4040
-- checks for WHNF without recursing. Hence we can throw if we reach this clause somehow.
4141
-- TODO: remove the CPP when rest of IOE moves to nothunks>=0.2
42-
#if MIN_VERSION_nothunks(0,2,0)
42+
#if MIN_VERSION_nothunks(0,3,0)
43+
BuiltinCostedResult _ _ -> pure . Just $ ThunkInfo ctx Nothing
44+
#elif MIN_VERSION_nothunks(0,2,0)
4345
BuiltinCostedResult _ _ -> pure . Just . ThunkInfo $ Left ctx
4446
#else
4547
-- Plutus has moved to nothunks>=0.2, but some other IOE repos are using nothunks<0.2.
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
<!--
2+
A new scriv changelog fragment.
3+
4+
Uncomment the section that is right (remove the HTML comment wrapper).
5+
For top level release notes, leave all the headers commented out.
6+
-->
7+
8+
<!--
9+
### Removed
10+
11+
- A bullet item for the Removed category.
12+
13+
-->
14+
<!--
15+
### Added
16+
17+
- A bullet item for the Added category.
18+
19+
-->
20+
### Changed
21+
22+
- Add support for nothunks == 0.3.*
23+
24+
<!--
25+
### Deprecated
26+
27+
- A bullet item for the Deprecated category.
28+
29+
-->
30+
<!--
31+
### Fixed
32+
33+
- A bullet item for the Fixed category.
34+
35+
-->
36+
<!--
37+
### Security
38+
39+
- A bullet item for the Security category.
40+
41+
-->

plutus-ledger-api/plutus-ledger-api.cabal

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ library
121121
, deepseq
122122
, lens
123123
, mtl
124-
, nothunks ^>=0.2
124+
, nothunks >=0.2 && <0.4
125125
, plutus-core ^>=1.55
126126
, plutus-tx ^>=1.55
127127
, prettyprinter

0 commit comments

Comments
 (0)