tarides / hackocaml

OCaml hacking ideas, small and large.
MIT License
19 stars 1 forks source link

Go through the OCaml5 tutorial, report issues and potentially fix them #3

Open kayceesrk opened 7 months ago

kayceesrk commented 7 months ago

https://github.com/kayceesrk/ocaml5-tutorial

plumenator commented 6 months ago

assign to me please?

kayceesrk commented 6 months ago

Done.

plumenator commented 6 months ago
# Domain.spawn;;
Alert deprecated: module Base.Domain
[2016-09] this element comes from the stdlib distributed with OCaml.
Referring to the stdlib directly is discouraged by Base. You should either
use the equivalent functionality offered by Base, or if you really want to
refer to the stdlib, use Stdlib.Domain instead

Is this due to my .ocamlinit?

 % cat ~/.ocamlinit
#use "topfind";;
#require "base";;
open Base;;
shindere commented 6 months ago

Side nte: it may be nice to add a link to the mentionned OCaml5 tutorial in the issue description?

kayceesrk commented 6 months ago

Seb, this is mentioned already https://github.com/tarides/HackaCamel/issues/3#issue-2142051894. Is that what you were looking for?

kayceesrk commented 6 months ago

Is this due to my .ocamlinit?

yes.

let main () = ...

The unit arg is necessary to make main a function and suspend the evaluation of the RHS expression until the function is applied. Otherwise, the expression on the RHS of = will be evaluated eagerly, and the result will be bound to the variable main.

shindere commented 6 months ago

KC Sivaramakrishnan (2024/03/11 01:55 -0700):

Seb, this is mentioned already https://github.com/tarides/HackaCamel/issues/3#issue-2142051894. Is that what you were looking for?

Yes, absolutely! Thanks a lot KC and sorry, I didn't realise the issue got opened before I subscribed to all notifications and had thus missed a few things!

plumenator commented 6 months ago

Opened ocaml-multicore/ocaml5-tutorial#15 and ocaml-multicore/ocaml5-tutorial#14. Solved the exercises at https://github.com/plumenator/ocaml5-tutorial/tree/solutions

kayceesrk commented 6 months ago

No problem Seb.