Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

camlp4/ pa_sml/ problem with curried functions in SML #3122

Closed
vicuna opened this issue Jan 4, 2002 · 2 comments
Closed

camlp4/ pa_sml/ problem with curried functions in SML #3122

vicuna opened this issue Jan 4, 2002 · 2 comments
Labels

Comments

@vicuna
Copy link

vicuna commented Jan 4, 2002

Original bug ID: 775
Reporter: administrator
Status: closed
Resolution: fixed
Priority: normal
Severity: minor
Category: ~DO NOT USE (was: OCaml general)

Bug description

Full_Name: David Scott
Version: 3.04 (both stable and cvs)
OS: Debian GNU/Linux testing on i386
Submission from: mozzarella.ulcc.wwwcache.ja.net (194.82.103.38)

With a simple SML file:

fun add x y = x + y

val result = add 1 2
<<<<

The camlp4 command
$ camlp4 pa_sml.cmo pr_o.cmo -- -verbose simple.ml

Generates the output:

let rec x (add, y) = x + y;;

let result = add 1 2;;
<<<<

With apparently the function name and the first argument switched around?
It works fine for functions with only one argument.

@vicuna
Copy link
Author

vicuna commented Jan 4, 2002

Comment author: administrator

Hi,

On Fri, Jan 04, 2002 at 01:28:47PM +0100, djs55@cam.ac.uk wrote:

let rec x (add, y) = x + y;;
let result = add 1 2;;

Thanks for this report. This is fixed now: it has been committed in
the current OCaml CVS version.

With apparently the function name and the first argument switched
around?

Because it was supposed to treat infix operators: in the change I have
done, the case of infix operators does not work any more, but will be
fixed later.

--
Daniel de RAUGLAUDRE
daniel.de_rauglaudre@inria.fr
http://cristal.inria.fr/~ddr/

@vicuna
Copy link
Author

vicuna commented Jan 11, 2002

Comment author: administrator

Fixed 2002-01-04 by DdR

@vicuna vicuna closed this as completed Jan 11, 2002
@vicuna vicuna added the bug label Mar 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant