We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I am using OCaml 4.09.0 from OPAM and I have just noticed something peculiar using the toplevel.
When evaluating 1 :: 2 :: [], the list is pretty-printed as usual:
1 :: 2 :: []
# 1 :: 2 :: 3 :: [] ;; - : int list = [1; 2; 3]
If I open first the List module, then the printing is different:
List
# let open List in 1 :: 2 :: 3 :: [] ;; - : int List.t = (::) (1, [2; 3])
The list is now typed with the type t used in the List module signature and the list representation is different.
t
Florian Angeletti has just posted an explanation on caml-list (see https://inbox.ocaml.org/caml-list/87v9ntdpx4.fsf@port-garion.isae.fr/T/#m81832d8a041da3a1306426ecd78944e95d47fd54) and a PR with a solution, see #9336.
Best,
Christophe
The text was updated successfully, but these errors were encountered:
The discussion on #9336 can supercede this issue.
Sorry, something went wrong.
No branches or pull requests
I am using OCaml 4.09.0 from OPAM and I have just noticed something peculiar using the toplevel.
When evaluating
1 :: 2 :: []
, the list is pretty-printed as usual:If I open first the
List
module, then the printing is different:The list is now typed with the type
t
used in theList
module signatureand the list representation is different.
Florian Angeletti has just posted an explanation on caml-list (see https://inbox.ocaml.org/caml-list/87v9ntdpx4.fsf@port-garion.isae.fr/T/#m81832d8a041da3a1306426ecd78944e95d47fd54) and a PR with a solution, see #9336.
Best,
Christophe
The text was updated successfully, but these errors were encountered: