Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0004939OCamlCamlp4public2009-12-14 06:552013-08-31 12:46
Reporterfuruse 
Assigned Toertai 
PrioritynormalSeveritymajorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version3.11.1 
Target VersionFixed in Version3.12.1+dev 
Summary0004939: CamlP4 does not like patterns like: ?x:_
DescriptionSorry for submitting small problems repeatedly.

let f ?l:_ () = ()

is rejected by camlp4o. The fix is :

--- a/camlp4/Camlp4Parsers/Camlp4OCamlParser.ml
+++ b/camlp4/Camlp4Parsers/Camlp4OCamlParser.ml
@@ -629,6 +629,8 @@
             <:patt< ~ $i$ : ($lid:i$ : $t$) >>
         | i = a_OPTLABEL; j = a_LIDENT -> (* ?a:b <> ?a : b *)
             <:patt< ? $i$ : ($lid:j$) >>
+ | i = a_OPTLABEL; "_" ->
+ <:patt< ? $i$ : (_) >>
         | i = a_OPTLABEL; "("; p = patt; ")" ->
             <:patt< ? $i$ : ($p$) >>
         | i = a_OPTLABEL; "("; p = patt; "="; e = expr; ")" ->
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
2009-12-14 06:55 furuse New Issue
2009-12-14 06:55 furuse Status new => assigned
2009-12-14 06:55 furuse Assigned To => ertai
2011-05-10 16:48 xclerc Status assigned => resolved
2011-05-10 16:48 xclerc Fixed in Version => 3.12.1+dev
2011-05-10 16:48 xclerc Resolution open => fixed
2013-08-31 12:46 xleroy Status resolved => closed


Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker