Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0004312OCamlCamlp4public2007-06-12 11:452010-04-29 14:26
Reporteralexbaretta 
Assigned Toertai 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version3.10.0 
Target VersionFixed in Version3.10+dev 
Summary0004312: camlp4o parsing issue for "let _" patterns
DescriptionThe following terminal session shows how camlp4o 3.10.0 fails to parse input that was accepted by 3.09.3.

> let _ : int = 1

Notice how the campl4 parser remains in an inconsistent state and fails to parse the line following the one that causes the error.

It is interesting to notice that the yacc parser never accepted such input, which also seems strange.
andrea@alex:~$ /opt/ocaml/3.09.3/bin/ocaml
        Objective Caml version 3.09.3

# let _ : int = 1;;
Syntax error
# #load "camlp4o.cma";;
        Camlp4 Parsing version 3.09.3

# let _ : int = 1;;
- : int = 1
#

Additional Informationalex@alex:~/dev/ocaml_asxcaml$ ocaml
        Objective Caml version 3.10.0

        Camlp4 Parsing version 3.10.0

# let _ : int = 1;;
Parse error: "module" or [opt_rec] expected after "let" (in [str_item])
# 1;;
Unbound value int
#
alex@alex:~/dev/ocaml_asxcaml$ /opt/ocaml/3.09.3/bin/ocaml
        Objective Caml version 3.09.3

        Camlp4 Parsing version 3.09.3

# let _ : int = 1;;
- : int = 1
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0004357)
ertai (developer)
2007-11-27 13:48

In the mean time the simplest solution was to make it works again.
One should consider if we'd better reject it later.

This is now fixed in the CVS (trunk and release310 branch).

- Issue History
Date Modified Username Field Change
2007-06-12 11:45 alexbaretta New Issue
2007-11-10 15:26 xleroy Status new => assigned
2007-11-10 15:26 xleroy Assigned To => ertai
2007-11-27 13:48 ertai Note Added: 0004357
2007-11-27 13:48 ertai Status assigned => resolved
2007-11-27 13:48 ertai Resolution open => fixed
2007-11-27 13:48 ertai Fixed in Version => 3.10+dev
2010-04-29 14:26 xleroy Status resolved => closed


Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker