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

Variables de rangee faibles & signaturess #2640

Closed
vicuna opened this issue Dec 14, 2000 · 1 comment
Closed

Variables de rangee faibles & signaturess #2640

vicuna opened this issue Dec 14, 2000 · 1 comment
Labels

Comments

@vicuna
Copy link

vicuna commented Dec 14, 2000

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

Bug description

Full_Name: Sylvain Boulme
Version: 3.00
OS: Linux RedHat 6.2
Submission from: cerdon.lip6.fr (132.227.83.56)

Le parser (et le typeur ?) dans le toplevel reagit de facon anormale en
presence
de variables de rangee faibles dans les signatures.

Par exemple, sous l'hypothese du code suivant :

class foo =
object
method printA = "A"
end;;

module Titi =
struct
let f y (x:#foo) = x
let blah = f 0
end;;

Le module "Titi" a la signature :

sig
val f : 'a -> (#foo as 'b) -> 'b
val blah : (_#foo as 'a) -> 'a
end

Si on essaye de definir :

module type Toto =
sig
val f : 'a -> (#foo as 'b) -> 'b
val blah : (_#foo as 'a) -> 'a
end

La reponse est
The type constructor foo expects 0 argument(s),
but is here applied to 1 argument(s)

De meme, si on essaye de definir :

module type Toto =
sig
val blah : < printA: string; _..>
end;;

La reponse est
Syntax error: 'end' expected, the highlighted 'sig' might be unmatched

Cordialement,

Sylvain.

@vicuna
Copy link
Author

vicuna commented Dec 15, 2000

Comment author: administrator

The user cannot input weak type variables. Only the compiler can show them.

@vicuna vicuna closed this as completed Dec 15, 2000
@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