2019-08-26 20:04 AEST

View Issue Details Jump to Notes ]
IDProjectCategoryView StatusLast Update
0000167mercuryBugpublic2010-11-04 17:40
Reportermgiuca 
Assigned To 
PrioritynormalSeverityminorReproducibilityalways
StatusnewResolutionopen 
Product Version 
Target VersionFixed in Version 
Summary0000167: bimap.init could be uo
DescriptionThe mode of bimap.init is:
:- func bimap.init = bimap(K, V).
:- pred bimap.init(bimap(K, V)::out) is det.

Note that the mode of map.init is:
:- pred map.init(map(_, _)::uo) is det.
:- func map.init = (map(K, V)::uo) is det.

For consistency, bimap.init's mode could be upgraded to uo, which shouldn't cause any problems:
:- func bimap.init = (bimap(K, V)::uo) is det.
:- pred bimap.init(bimap(K, V)::uo) is det.

(I've tried it and it compiles fine, as does code which depends on it.)

This would be useful for programs trying to use uniqueness where possible.
TagsNo tags attached.
Attached Files

-Relationships
+Relationships

-Notes
There are no notes attached to this issue.
+Notes

-Issue History
Date Modified Username Field Change
2010-11-04 17:40 mgiuca New Issue
+Issue History