companion_cube changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org | OCaml 4.11 release notes: https://caml.inria.fr/pub/distrib/ocaml-4.11/notes/Changes | Try OCaml in your browser: http://try.ocamlpro.com | Public channel logs at http://irclog.whitequark.org/ocaml
reynir has joined #ocaml
Haudegen has quit [Ping timeout: 246 seconds]
mxns has quit [Ping timeout: 264 seconds]
mxns has joined #ocaml
zebrag has quit [Quit: Konversation terminated!]
zebrag has joined #ocaml
borne has quit [Ping timeout: 244 seconds]
mxns has quit [Ping timeout: 272 seconds]
amiloradovsky has quit [Remote host closed the connection]
inkbottle has joined #ocaml
zebrag has quit [Ping timeout: 240 seconds]
reynir has quit [Remote host closed the connection]
reynir has joined #ocaml
vesper11 has joined #ocaml
Tuplanolla has quit [Quit: Leaving.]
steenuil_ has quit [Read error: Connection reset by peer]
mxns has joined #ocaml
andreas303 has quit [Remote host closed the connection]
andreas303 has joined #ocaml
mfp has quit [Ping timeout: 265 seconds]
mxns has quit [Ping timeout: 240 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 264 seconds]
mxns has joined #ocaml
zebrag has joined #ocaml
inkbottle has quit [Ping timeout: 260 seconds]
madroach has quit [Ping timeout: 256 seconds]
madroach has joined #ocaml
yomimono has quit [Ping timeout: 240 seconds]
mxns has quit [Ping timeout: 240 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 246 seconds]
mxns has joined #ocaml
narimiran has joined #ocaml
yomimono has joined #ocaml
waleee-cl has quit [Quit: Connection closed for inactivity]
mxns has quit [Ping timeout: 272 seconds]
ansiwen has quit [Quit: ZNC 1.7.1 - https://znc.in]
mxns has joined #ocaml
ansiwen has joined #ocaml
vicfred has quit [Remote host closed the connection]
vicfred has joined #ocaml
vicfred has quit [Max SendQ exceeded]
aaaaaa has quit [Quit: leaving]
decentpenguin has quit [Quit: ZNC crashed or something]
decentpenguin has joined #ocaml
Haudegen has joined #ocaml
ggole has joined #ocaml
mxns has quit [Ping timeout: 264 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 260 seconds]
steenuil has joined #ocaml
<d_bot> <argent_smith> hi ppl. How can I "re-export" a module sitting in a separate ml/mli files as a nested module? (I'm writing a lib)
<d_bot> <craigfe> @argent_smith: if you're using Dune – w/ a toplevel `.ml` file of the same name as the lib – you can do `module Other = Other` inside that file
<d_bot> <argent_smith> thnx @craigfe
mfp has joined #ocaml
borne has joined #ocaml
hnOsmium0001 has quit [Quit: Connection closed for inactivity]
brown121407 has quit [Ping timeout: 260 seconds]
bartholin has joined #ocaml
mxns has joined #ocaml
berberman_ has joined #ocaml
berberman has quit [Ping timeout: 272 seconds]
mxns has quit [Ping timeout: 256 seconds]
reynir has quit [Ping timeout: 240 seconds]
reynir has joined #ocaml
noonien has quit [Ping timeout: 256 seconds]
noonien has joined #ocaml
daimrod has joined #ocaml
mbuf has joined #ocaml
mxns has joined #ocaml
mxns has quit [Ping timeout: 272 seconds]
nullcone has quit [Quit: Connection closed for inactivity]
vesper11 has quit [Ping timeout: 240 seconds]
Haudegen has quit [Quit: Bin weg.]
mxns has joined #ocaml
waleee-cl has joined #ocaml
mxns has quit [Ping timeout: 272 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 256 seconds]
mxns has joined #ocaml
Anarchos has joined #ocaml
mxns has quit [Ping timeout: 260 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 272 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 240 seconds]
dhil has joined #ocaml
Haudegen has joined #ocaml
mxns has joined #ocaml
mxns has quit [Quit: ZNC 1.8.2 - https://znc.in]
mxns has joined #ocaml
mbuf has quit [Ping timeout: 256 seconds]
Anarchos has quit [Quit: Vision[0.10.3]: i've been blurred!]
motherfsck has quit [Quit: quit]
motherfsck has joined #ocaml
mxns has quit [Ping timeout: 272 seconds]
mxns has joined #ocaml
vicfred has joined #ocaml
chripell has quit [Quit: ZNC 1.8.1+deb1+build2 - https://znc.in]
chripell has joined #ocaml
brown121407 has joined #ocaml
brown121407 has joined #ocaml
nullcone has joined #ocaml
hnOsmium0001 has joined #ocaml
Haudegen has quit [Quit: Bin weg.]
urek has joined #ocaml
mxns has quit [Ping timeout: 244 seconds]
mxns has joined #ocaml
bartholin has quit [Quit: Leaving]
Tuplanolla has joined #ocaml
urek has quit [Quit: urek]
ggole has quit [Quit: Leaving]
Haudegen has joined #ocaml
c4rc4s has joined #ocaml
aaaaaa has joined #ocaml
nullcone has quit [Quit: Connection closed for inactivity]
vicfred has quit [Ping timeout: 240 seconds]
vicfred has joined #ocaml
vicfred has quit [Quit: Leaving]
borne has quit [Ping timeout: 240 seconds]
berberman_ has quit [Ping timeout: 246 seconds]
berberman has joined #ocaml
reynir has quit [Remote host closed the connection]
reynir has joined #ocaml
reynir has quit [Remote host closed the connection]
reynir has joined #ocaml
mxns has quit [Ping timeout: 246 seconds]
vicfred has joined #ocaml
Jesin has quit [Quit: Leaving]
Jesin has joined #ocaml
mxns has joined #ocaml
amiloradovsky has joined #ocaml
<d_bot> <Cyclomatic Complexity> hi
<d_bot> <Cyclomatic Complexity> how can i define `a_to_b` here?
<d_bot> <Cyclomatic Complexity> ```ocaml
<d_bot> <Cyclomatic Complexity> type a_tag = [`A]
<d_bot> <Cyclomatic Complexity> type b_tag = [`B]
<d_bot> <Cyclomatic Complexity> type c_tag = [`C]
<d_bot> <Cyclomatic Complexity>
<d_bot> <Cyclomatic Complexity> type 'a ast =
<d_bot> <Cyclomatic Complexity> | Foo : [a_tag | b_tag] ast
<d_bot> <Cyclomatic Complexity> | Bar : [b_tag | c_tag] ast
<d_bot> <Cyclomatic Complexity> | Wee : [a_tag | c_tag] ast
<d_bot> <Cyclomatic Complexity>
<d_bot> <Cyclomatic Complexity>
<d_bot> <Cyclomatic Complexity> type a = a_tag ast
<d_bot> <Cyclomatic Complexity> type b = b_tag ast
<d_bot> <Cyclomatic Complexity> type c = c_tag ast
<d_bot> <Cyclomatic Complexity>
<d_bot> <Cyclomatic Complexity> let a_to_b : a -> b = function
<d_bot> <Cyclomatic Complexity> | Foo -> Bar
<d_bot> <Cyclomatic Complexity> | Wee -> Foo
<d_bot> <Cyclomatic Complexity> ```
<d_bot> <craigfe> ```ocaml
<d_bot> <craigfe> let a_to_b : a -> b = function _ -> .
<d_bot> <craigfe> ```
<d_bot> <craigfe>
<d_bot> <craigfe> 😁
<d_bot> <craigfe> Your type `a` is uninhabited, since your polymorphic variants are all closed
<d_bot> <Cyclomatic Complexity> @craigfe waat
<d_bot> <Cyclomatic Complexity> How can I make them open then?
<d_bot> <Cyclomatic Complexity> oh ye <
<d_bot> <craigfe> Probably `>` rather than `<`, but yes πŸ™‚
<d_bot> <Cyclomatic Complexity> ```ocaml
<d_bot> <Cyclomatic Complexity> type foo = [> `Foo]
<d_bot> <Cyclomatic Complexity> type bar = [> `Bar]
<d_bot> <Cyclomatic Complexity> type wee = [> `Wee]
<d_bot> <Cyclomatic Complexity>
<d_bot> <Cyclomatic Complexity> type +'a ast =
<d_bot> <Cyclomatic Complexity> | Foo : foo ast
<d_bot> <Cyclomatic Complexity> | Bar : bar ast
<d_bot> <Cyclomatic Complexity> | Wee : wee ast
<d_bot> <Cyclomatic Complexity>
<d_bot> <Cyclomatic Complexity> type a = [foo | bar] ast
<d_bot> <Cyclomatic Complexity> type b = [bar | wee] ast
<d_bot> <Cyclomatic Complexity>
<d_bot> <Cyclomatic Complexity> let a_to_b : a -> b = function
<d_bot> <Cyclomatic Complexity> | Foo -> Bar
<d_bot> <Cyclomatic Complexity> | Wee -> Foo
<d_bot> <Cyclomatic Complexity> ```
<d_bot> <Cyclomatic Complexity> ```
<d_bot> <Cyclomatic Complexity> Line 1, characters 0-19:
<d_bot> <Cyclomatic Complexity> Error: A type variable is unbound in this type declaration.
<d_bot> <Cyclomatic Complexity> In type [> `Foo ] as 'a the variable 'a is unbound
<d_bot> <Cyclomatic Complexity> ```
vesper11 has joined #ocaml
<d_bot> <craigfe> Indeed. Open polymorphic variants are implemented by keeping an unbound type variable around
<d_bot> <craigfe> So your definition ``type foo = [> `Foo ]`` has a hidden unbound type variable that panics the type-checker
<d_bot> <craigfe> Try this:
<d_bot> <craigfe> ```ocaml
<d_bot> <craigfe> type 'a ast =
<d_bot> <craigfe> | Foo : [< a_tag | b_tag] ast
<d_bot> <craigfe> | Bar : [< b_tag | c_tag] ast
<d_bot> <craigfe> | Wee : [< a_tag | c_tag] ast
<d_bot> <craigfe> ```
vesper has joined #ocaml
vesper11 has quit [Ping timeout: 240 seconds]
tane has joined #ocaml
narimiran has quit [Ping timeout: 260 seconds]
jnavila has joined #ocaml
dhil has quit [Ping timeout: 265 seconds]
vesper has quit [Ping timeout: 265 seconds]
borne has joined #ocaml
zebrag has quit [Quit: Konversation terminated!]
zebrag has joined #ocaml
vesper11 has joined #ocaml
dhil has joined #ocaml
<d_bot> <Cyclomatic Complexity> @craigfe Can you check the latter code I sent? The former was not what I wanted
<d_bot> <Cyclomatic Complexity> Rather than specifying on each ast case which ast support it, i am more interested in specifying on each ast, which cases it supports
jnavila has quit [Quit: Konversation terminated!]
amiloradovsky has quit [Remote host closed the connection]
amiloradovsky has joined #ocaml
mxns has quit [Ping timeout: 246 seconds]
infinity0 has quit [Remote host closed the connection]
lix has quit [Ping timeout: 260 seconds]
infinity0 has joined #ocaml
lix has joined #ocaml
mxns has joined #ocaml
tane has quit [Quit: Leaving]
jgkamat has left #ocaml ["Using Circe, the loveliest of all IRC clients"]
infinity0 has quit [Remote host closed the connection]
mxns has quit [Ping timeout: 240 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 272 seconds]
infinity0 has joined #ocaml
Haudegen has quit [Ping timeout: 246 seconds]
<d_bot> <dj charlie> How many Jane street patches fail to get into the compiler?
<d_bot> <dj charlie> Very curious if there’s a way to see easily
amiloradovsky has quit [Remote host closed the connection]
amiloradovsky has joined #ocaml
reynir has quit [Ping timeout: 240 seconds]