[GHC] #4459: Polymorphic Data.Dynamic
GHC
cvs-ghc at haskell.org
Sat Jun 25 08:54:05 CEST 2011
#4459: Polymorphic Data.Dynamic
-----------------------------------------------------+----------------------
Reporter: vivian | Owner: vivian
Type: feature request | Status: new
Priority: normal | Milestone: 7.4.1
Component: GHC API | Version: 7.1
Keywords: polymorphic, dynamic, class, linking | Testcase:
Blockedby: | Difficulty:
Os: Unknown/Multiple | Blocking: 4316
Architecture: Unknown/Multiple | Failure: None/Unknown
-----------------------------------------------------+----------------------
Comment(by vivian):
I currently can load a module and bind the `TyThing` and `HValue` of a
top-level entity
{{{
data DynamicHValue = DynamicHValue TyThing HValue
}}}
When I want to apply a `DynamicHValue` to another `DynamicHValue` (an App
operation)
* I can figure out the resulting type using `mkAppTy` but that takes
`Type`s not `TyThings`. What is the correct way of getting a `Type` from
a `TyThing`?
* I want to apply one HValue to another. What is the correct approach?
The second item is not so straight-forward, because the applied `HValue`
might cause the resultant type to be less generic. A class instance might
specialise the function type, in which case the linker has to link the
appropriate instance.
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/4459#comment:7>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the Glasgow-haskell-bugs
mailing list