mirror of
https://github.com/github/semantic.git
synced 2024-12-27 00:44:57 +03:00
Constrain the value type in the allocator type.
This commit is contained in:
parent
f17607bdf8
commit
40eb2201da
@ -22,9 +22,9 @@ deref addr = do
|
||||
maybeM (throwAddressError (UninitializedAddress addr)) derefed
|
||||
|
||||
|
||||
data Allocator location return where
|
||||
Alloc :: Name -> Allocator location (Address location value)
|
||||
Deref :: Address location value -> Allocator location value
|
||||
data Allocator location value return where
|
||||
Alloc :: Name -> Allocator location value (Address location value)
|
||||
Deref :: Address location value -> Allocator location value value
|
||||
|
||||
|
||||
-- | Defines 'alloc'ation and 'deref'erencing of 'Address'es in a Heap.
|
||||
|
Loading…
Reference in New Issue
Block a user