Can warning 42 be ignored?

I’m wondering if I should ignore the warning:

Warning 42: this use of speclist relies on type-directed disambiguation, it will not compile with OCaml 4.00 or earlier.

I don’t care about compatibility with old compilers; but is relying on type-directed disambiguation a code smell? Will it make my code more fragile and/or less readable?

Relying on type directed disambiguation is now a part of modern OCaml style, and many libraries are relying while providing their interfaces. See also the discussion here. So if you are not bothered with 3.x and 4.00 compatibility, then go ahead :slight_smile:

1 Like

ok, that sounds reasonable. in fact, i had not realized that in the project i was building, a non-standard set of warnings was enabled, so i was not aware that 42 is off by default.