Mercury Bugs - mercury
View Issue Details
0000264mercuryBugpublic2012-10-02 22:552015-11-02 16:55
Reporterwangp 
Assigned Tozs 
PrioritynormalSeverityminorReproducibilityalways
StatusresolvedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0000264: function mode lost without warning
DescriptionIt's possible to place a function with non-default mode into a ground term then extract it back out, now with the default mode assumed.

According to the manual this should be forbidden:

   As a consequence of this, it is a mode error to pass a higher-order
function term that does not match this standard mode to somewhere where
its higher-order inst information may be lost[...]

which was apparently implemented:
http://www.mercury.csse.unimelb.edu.au/mailing-lists/mercury-users/mercury-users.0308/0013.html
TagsNo tags attached.
Attached Files? default_ho_inst.m (482) 2012-10-02 22:55
https://bugs.mercurylang.org/file_download.php?file_id=161&type=bug

Notes
(0000865)
zs   
2015-11-02 16:55   
Fix committed 2015 nov 2.

Issue History
2012-10-02 22:55wangpNew Issue
2012-10-02 22:55wangpFile Added: default_ho_inst.m
2015-11-02 16:55zsNote Added: 0000865
2015-11-02 16:55zsStatusnew => resolved
2015-11-02 16:55zsResolutionopen => fixed
2015-11-02 16:55zsAssigned To => zs