IntersectMBO / IntersectMBO/plutus
Cannot compile some phantom types
- Dominant language
- Haskell
- Stars
- 1.6k
- Forks
- 508
- Avg merge
- 3d 10h
- Merged PRs (30d)
- 22
Description
### Summary
A pir compile error
```
: error:
GHC Core to PLC plugin: Error: Error from the PIR compiler:
Error during compilation: Type bindings cannot appear in recursive let, use datatypebind instead
```
This happens with the code
```
newtype Phantom a = Phantom ()
compiledPhantom = $$(compile [|| Phantom () :: Phantom Ordering ||])
```
It happens when phantom type is Ordering, Either...
It does not happen when phantom types is Bool or ()
### Steps to reproduce the behavior
_No response_
### Actual Result
_No response_
### Expected Result
_No response_
### Describe the approach you would take to fix this
_No response_
### System info
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.