unsafeLookupStaticPtr should not live in IO
GHC.StaticPtr provides
unsafeLookupStaticPtr :: StaticKey -> IO (Maybe (StaticPtr a))
I don't think this function should live in IO. It is morally pure (the SPT that it needs to access is static for the duration of the program after all) and when this lives in IO this function cannot be used in Binary instances (without using unsafePerformIO, obviously).
Trac metadata
| Trac field | Value |
|---|---|
| Version | 8.0.1-rc1 |
| Type | Bug |
| TypeOfFailure | OtherFailure |
| Priority | normal |
| Resolution | Unresolved |
| Component | Compiler |
| Test case | |
| Differential revisions | |
| BlockedBy | |
| Related | |
| Blocking | |
| CC | |
| Operating system | |
| Architecture |