Leonidas changed the topic of #ocaml to: Discussion about the OCaml programming language | http://www.ocaml.org | OCaml 5.1.1 released: https://ocaml.org/releases/5.1.1 | Try OCaml in your browser: https://try.ocamlpro.com | Public channel logs at https://libera.irclog.whitequark.org/ocaml/
<discocaml> <barconstruction> dh, by sealing I meant
<discocaml> <barconstruction> module M : sig
<discocaml> <barconstruction> ...
<discocaml> <barconstruction> end
<discocaml> <barconstruction> = struct
<discocaml> <barconstruction> ...
<discocaml> <barconstruction> end
<discocaml> <barconstruction> And by "checking that a module implements the signature" I meant in a non sealing way, something like
<discocaml> <barconstruction> module M = struct ... end
<discocaml> <barconstruction> module M' : sig ... end = M
<discocaml> <barconstruction>
<discocaml> <barconstruction> Here M' is not supposed to be used anywhere else it is just a compile time check that the module provides the functionality you want it to, guaranteeing that it can be used at certain points in the program (even if it isn't currently)
<discocaml> <barconstruction>
<discocaml> <barconstruction> It is a subjective distinction to say that one is more valuable than the other, my reasoning is that it's less common to have multiple modules implementing the exact same exposed functionality, but more common to have multiple modules which implement at least so much functionality at the client side point where they will be used.
jabuxas has quit [Quit: oops :p]
jabuxas has joined #ocaml
jabuxas has quit [Remote host closed the connection]
jabuxas has joined #ocaml
gentauro has quit [Read error: Connection reset by peer]
jabuxas has quit [Quit: oops :p]
waleee has quit [Ping timeout: 268 seconds]
jabuxas has joined #ocaml
<discocaml> <yawaramin> `module _ : S = M` also works
gentauro has joined #ocaml
jabuxas has quit [Read error: Connection reset by peer]
jabuxas has joined #ocaml
gzar has quit [Quit: WeeChat 4.2.2]
<dh`> ah, I see what you mean
<dh`> not sure I agree though, for separate-compilation modules you always want sealing (otherwise there's little point)
<dh`> and in most other cases you're doing functor works and in those it is also often highly desirable to seal off the internals
<discocaml> <limp.biskit> does containers have an equivalent to Base.List.split_n?
<discocaml> <barconstruction> I think we are partially on the same page about functors. A functor cannot access any part of the module it relies on beyond what is declared in the interface specified by the client (the author of the functor) and I think that interface should be written explicitly as a signature.
<discocaml> <barconstruction> I agree that "it is highly desirable to seal off the internals" but one can leave that to the functor author who writes an interface specifying what the module type of its argument should be.
<discocaml> <barconstruction>
<discocaml> <barconstruction> My point is more about the principal signature for the module that it exposes to the rest of the program.
jabuxas has quit [Read error: Connection reset by peer]
jabuxas has joined #ocaml
oriba has quit [Ping timeout: 264 seconds]
jabuxas has quit [Read error: Connection reset by peer]
jabuxas has joined #ocaml
jabuxas has quit [Remote host closed the connection]
jabuxas has joined #ocaml
jabuxas has quit [Quit: oops :p]
jabuxas has joined #ocaml
jabuxas has quit [Read error: Connection reset by peer]
jabuxas has joined #ocaml
jabuxas has quit [Remote host closed the connection]
dh` has quit [Read error: Connection reset by peer]
dh` has joined #ocaml
jabuxas has joined #ocaml
jabuxas has quit [Quit: oops :p]
jabuxas has joined #ocaml
jabuxas has quit [Read error: Connection reset by peer]
jabuxas has joined #ocaml
trillion_exabyte has quit [Read error: Connection reset by peer]
trillion_exabyte has joined #ocaml
<anadon> dh`: I'd like to use your split3.ml wholesale in my project, copyright to you GPLv3 or similar in a standalone file. Is that OK with you? I'd add attributions at the top as usual and code would live at https://gitlab.com/anadon/detect_programs_called_from_script
jabuxas has quit [Remote host closed the connection]
jabuxas has joined #ocaml
jabuxas has quit [Ping timeout: 260 seconds]
mbuf has joined #ocaml
dh` has quit [Read error: Connection reset by peer]
dh` has joined #ocaml
deadmarshal_ has quit [Remote host closed the connection]
deadmarshal_ has joined #ocaml
Serpent7776 has joined #ocaml
wingsorc has quit [Ping timeout: 256 seconds]
bartholin has joined #ocaml
mro has joined #ocaml
torretto_ has joined #ocaml
torretto has quit [Ping timeout: 260 seconds]
haesbaert has joined #ocaml
myrkraverk has joined #ocaml
trillion_exabyte has quit [Ping timeout: 240 seconds]
trillion_exabyte has joined #ocaml
jabuxas has joined #ocaml
ocra8 has joined #ocaml
jabuxas has quit [Read error: Connection reset by peer]
Guest1199 has joined #ocaml
Guest1199 has quit [Client Quit]
jabuxas has joined #ocaml
jabuxas has quit [Quit: oops :p]
jabuxas has joined #ocaml
jabuxas has quit [Read error: Connection reset by peer]
jabuxas has joined #ocaml
jabuxas has quit [Quit: oops :p]
jabuxas has joined #ocaml
myrkraverk_ has joined #ocaml
myrkraverk has quit [Read error: Connection reset by peer]
jabuxas has quit [Quit: oops :p]
jabuxas has joined #ocaml
bartholin has quit [Quit: Leaving]
waleee has joined #ocaml
jabuxas has quit [Quit: oops :p]
jabuxas has joined #ocaml
average has joined #ocaml
waleee has quit [Ping timeout: 264 seconds]
jabuxas has quit [Quit: oops :p]
jabuxas has joined #ocaml
waleee has joined #ocaml
mro has quit [Quit: Leaving]
average has quit [Quit: Connection closed for inactivity]
jabuxas has quit [Quit: oops :p]
jabuxas has joined #ocaml
jabuxas has quit [Client Quit]
jabuxas has joined #ocaml
mbuf_ has joined #ocaml
mbuf has quit [Ping timeout: 268 seconds]
mbuf_ has quit [Remote host closed the connection]
mbuf_ has joined #ocaml
ocra8 has quit [Ping timeout: 268 seconds]
ocra8 has joined #ocaml
Serpent7776 has quit [Ping timeout: 252 seconds]
mbuf_ has quit [Quit: Leaving]
trillion_exabyte has quit [Ping timeout: 260 seconds]
trillion_exabyte has joined #ocaml
jabuxas has quit [Ping timeout: 268 seconds]
torretto_ has quit [Ping timeout: 260 seconds]
torretto has joined #ocaml
<companion_cube> wow, JST is now using OCaml >= 5.1 in base!
bartholin has joined #ocaml
Tuplanolla has joined #ocaml
chrisz has quit [Quit: leaving]
torretto has quit [Remote host closed the connection]
torretto has joined #ocaml
pi3ce has quit [Quit: No Ping reply in 180 seconds.]
pi3ce has joined #ocaml
wingsorc has joined #ocaml
Armael has quit [Quit: WeeChat 4.1.1]
Armael has joined #ocaml
wingsorc has quit [Remote host closed the connection]
bartholin has quit [Quit: Leaving]
wingsorc has joined #ocaml
jabuxas has joined #ocaml