* Bug with cyclic abbreviations ?
@ 2005-06-02 13:08 Julien Verlaguet
2005-06-02 17:04 ` [Caml-list] " Frédéric Gava
2005-06-03 1:46 ` Jacques Garrigue
0 siblings, 2 replies; 3+ messages in thread
From: Julien Verlaguet @ 2005-06-02 13:08 UTC (permalink / raw)
To: caml-list
This is a problem that I only have when the -rectypes option is activated.
$./ocaml -rectypes
Objective Caml version 3.08.3
# type 'a t='a;;
type 'a t = 'a
# type cycle='a t as 'a;;
The type abbreviation cycle is cyclic
agreed.
# let (x : 'a t as 'a)=0;;
Fatal error: exception Stack_overflow
Shouldn't it detect the cyclic abbreviation in this case too ?
J
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Caml-list] Bug with cyclic abbreviations ?
2005-06-02 13:08 Bug with cyclic abbreviations ? Julien Verlaguet
@ 2005-06-02 17:04 ` Frédéric Gava
2005-06-03 1:46 ` Jacques Garrigue
1 sibling, 0 replies; 3+ messages in thread
From: Frédéric Gava @ 2005-06-02 17:04 UTC (permalink / raw)
To: caml-list
Hi,
> # let (x : 'a t as 'a)=0;;
> Fatal error: exception Stack_overflow
I have the same problem with
let _ = (fun () -> let (x : 'a t as 'a)=0 in 0);;
where the evaluation of the let has been freezed... so is it the type system
which loops ?
Frédéric Gava
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Caml-list] Bug with cyclic abbreviations ?
2005-06-02 13:08 Bug with cyclic abbreviations ? Julien Verlaguet
2005-06-02 17:04 ` [Caml-list] " Frédéric Gava
@ 2005-06-03 1:46 ` Jacques Garrigue
1 sibling, 0 replies; 3+ messages in thread
From: Jacques Garrigue @ 2005-06-03 1:46 UTC (permalink / raw)
To: Julien.Verlaguet; +Cc: caml-list, caml-bugs
From: Julien Verlaguet <Julien.Verlaguet@pps.jussieu.fr>
> This is a problem that I only have when the -rectypes option is activated.
>
> $./ocaml -rectypes
> Objective Caml version 3.08.3
>
> # type 'a t='a;;
> type 'a t = 'a
>
> # type cycle='a t as 'a;;
> The type abbreviation cycle is cyclic
>
> agreed.
>
> # let (x : 'a t as 'a)=0;;
> Fatal error: exception Stack_overflow
>
> Shouldn't it detect the cyclic abbreviation in this case too ?
Indeed, there was a bug in the occur check when using -rectypes.
I suppose this bug has always been there. Funny nobody found it
before.
This is now fixed in CVS (both 3.08 and 3.09).
By the way, there is a special address for bug reports. This helps
tracking them. (Fortunately this one was solved immediately.)
Jacques Garrigue
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2005-06-03 1:47 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-06-02 13:08 Bug with cyclic abbreviations ? Julien Verlaguet
2005-06-02 17:04 ` [Caml-list] " Frédéric Gava
2005-06-03 1:46 ` Jacques Garrigue
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox