News for hackers. Stuff that matters.
Re:Rust in 2018: easier to use by papaf on Sunday January 14, 2018 @03:51AM (#16143376)
I used OCaml a few years ago and I thought it was an excellent language. Despite being powerful it was really easy to learn.

One thing that put me off in the end was that it didn't support native OS threads (I have the same problem with Racket). Has threading support improved over the years?

Re:Rust in 2018: easier to use by grayrest on Sunday January 14, 2018 @05:33AM (#16143647)
> Has threading support improved over the years?

The main push in this area is Multicore OCaml[1]. I don't track OCaml closely enough to know how getting this into the main compiler is going.

[1] https://github.com/ocamllabs/ocaml-multicore/wiki

Re:Rust in 2018: easier to use by StreamBright on Sunday January 14, 2018 @07:48AM (#16144047)
I am not sure what exactly you are missing, isn't this a native OS thread either POSIX or Win32?

http://caml.inria.fr/pub/docs/manual-ocaml/libref/Thread.htm...

Re:Rust in 2018: easier to use by papaf on Sunday January 14, 2018 @03:58PM (#16146387)
The documentation that you linked to is not describing native OS threads. I am sure that the OCaml implementation is good for a lot of applications.

However, because I am used to writing multithreaded code using pthread or std::thread, I find the standard OCaml model uncomfortable and limiting. Its mostly a matter of personal taste but this is the reason I stopped using OCaml.

Re:Rust in 2018: easier to use by seertaak on Sunday January 14, 2018 @01:53PM (#16145600)
I tried it too; after I realized I that every struct had to have unique field names, I gave up. This was too much craziness for me, although I did think the module/functor concepts were very cool.
Re:Rust in 2018: easier to use by ernst_klim on Tuesday January 16, 2018 @03:42AM (#16156681)
>I that every struct had to have unique field names

Nope, different structs could have fields named the same.

Re:Rust in 2018: easier to use by masoodusmani on Sunday January 14, 2018 @10:33AM (#16144640)
Are you sure Racket doesn't support native threads? I thought it had something called "places" for that.
Re:Rust in 2018: easier to use by papaf on Sunday January 14, 2018 @03:46PM (#16146307)
I did not know about places, but after reading about them [1], I can see that although they are implemented on top of OS threads, it is not a conventional threading model.

For instance there is an instance of the Racket VM per place and this makes them heavier than it would be in a standard system programming language language such as C, C++ or Rust.

I am not saying it is better or worse -- just different.

[1] https://www.cs.utah.edu/plt/publications/dls11-tsffd.pdf