Skip to content

Documentation for CoreMonad.getAnnotations

The documentation for getAnnotations in CoreMonad is a bit unclear. In particular, the documentation could be improved by indicating that the returned UniqFM is keyed off of the Unique corresponding to an AnnTarget: That is, to look up the annotations on x, it seems one should call getAnnotations on either ModuleTarget x or NamedTarget x (if my understanding of how this all works is correct, that is).

I stumbled across this by trying to look up the annotations on module m using the key getUnique m. This was incorrect as the annotation is stored on a unique *derived* from getUnique m (which wasn't indicated in the documentation).

Thanks!

Trac metadata
Trac field Value
Version 7.10.3
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Documentation
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information