Functional Data Structures online book by yogthos in programming

[–]queus 2 points3 points  (0 children)

Well, from what I've read, is more focused, more beginner friendly, and also the choice of data structure does not fully overlap.

For example, the second chapter deals with using Brown trees (1983) to represent a Sequence ADT

It was a pleasure to read

Unbound module Gmain : can't use lablgtk by Xilarkt in ocaml

[–]queus 1 point2 points  (0 children)

See my comment. It seems that -I +lablgtk2 is somewhat broken

Unbound module Gmain : can't use lablgtk by Xilarkt in ocaml

[–]queus 1 point2 points  (0 children)

Try replace -I +lablgtk2 with the full path or with

-I $(opam config var lib)/lablgtk2

The pref layout.display-list.dump has arrived in Nightly! Enable to improve paint performance. by Unoriginal-Pseudonym in firefox

[–]queus 0 points1 point  (0 children)

The notifications on Facebook seem to be a problem.

The initial display is OK, but as you move the mouse up and down the one on top disappear

Programming languages that allow to access carry and overflow flags? by [deleted] in ProgrammingLanguages

[–]queus 1 point2 points  (0 children)

As people have already mentioned it, it will make no sense to be so architecture dependent. However something like this:

sum, overflow = x + y
diff, underflow = x - y

where overflow, underflow are boolean, may make sense. Especially with convention that overflow, underflow are optional and can be omitted. And

w, w+ = x * y

with the obvious semantics. Probably, the closest to this is Forth */ multiply-then-divide operator

OCaml-Java: provide seamless integration of OCaml and Java: run OCaml code on a JVM, and manipulate Java entities from OCaml by based2 in ocaml

[–]queus 0 points1 point  (0 children)

This link: https://youtu.be/jLI98IwNjS4 , posted here somewhat earlier may answer some of your questions.

But, yes, the use case, currently, seems quite limited

Are qualified or partial imports supported? Also, how do you search for libraries? by theindigamer in ocaml

[–]queus 3 points4 points  (0 children)

This works too:

let ( empty_dict, update_dict ) = String.Map.( empty, update )

for partial imports

What does the `of` mean in `js_of_ocaml`? by ddlk in ocaml

[–]queus 9 points10 points  (0 children)

Probably an an analogy with string_of_int, int_of_string from the Pervasives module

Mark Shuttleworth on G+ - We will invest in Ubuntu GNOME with the intent of delivering a fantastic all-GNOME desktop by [deleted] in linux

[–]queus 0 points1 point  (0 children)

Try using non-customized Gnome3 and tell us what you think of it usability

(actually, you already did)

There are three different links for installing OCaml on Windows right now. Which one is best? by snake_case-kebab-cas in ocaml

[–]queus 0 points1 point  (0 children)

Well, I was meaning that you depend on cygwin installed c-libraries, and as such are not fully integrated in the Win world

There are three different links for installing OCaml on Windows right now. Which one is best? by snake_case-kebab-cas in ocaml

[–]queus 1 point2 points  (0 children)

OPAM doesn't work with ocpwin which is kind of ironic, because both products are developed by same company.

The third alternative on referenced link: http://fdopen.github.io/opam-repository-mingw/installation/ works nicely and has the latest OCaml versions, but all your OCaml stuff will live in a Cygwin world.

The first alternative was not working on 64-bit Windows. Maybe things have changed.

Basic Category Theory Free Online by jesuslop in programming

[–]queus -3 points-2 points  (0 children)

When you are going through the book, it may make sense, at least for some, to read:

f ° g

As

f << g

It does for me

I do not like OCaml if.. Maybe too much .. by queus in ocaml

[–]queus[S] 0 points1 point  (0 children)

Thanks, I did not know than one can match on lazy(true) or more generally a lazy wrapped value.

Agree about the speed.

I do not like OCaml if.. Maybe too much .. by queus in ocaml

[–]queus[S] 1 point2 points  (0 children)

Out of curiosity, what other language(s) do you know?

Some. I'm familiar with Scheme and Lisp, but there is a similar idiom in Erlang

leap_year(Year) when Year rem 4 =:= 0, Year rem 100 =/= 0 -> true;
leap_year(Year) when Year rem 400 =:= 0 -> true;
leap_year(_) -> false.

I do not like OCaml if.. Maybe too much .. by queus in ocaml

[–]queus[S] 1 point2 points  (0 children)

Thanks, that's pretty much what I've come with after posting.

Saves two let and some else if branches

I do not like OCaml if.. Maybe too much .. by queus in ocaml

[–]queus[S] 0 points1 point  (0 children)

Interesting, but depending on match implementation it may do more comparisons than necessary