<ruffy_>
But why do I always reach the case where all are false?
<ZirconiumX>
ruffy_: please use a pastebin, it's basic etiquette
<reynir>
Do you set the fields of flags?
<ruffy_>
ZirconiumX: Sry, I will do that next time
<theblatte>
and is this evaluated before you actually set the flags?
<ruffy_>
reynir: I set them all to false in the beginning
<ruffy_>
theblatte: Hmmm normally it is evaluated afterwards, but maybe I have something wrong there
<thizanne>
ruffy_: to be clear, your code is correct. Your error is that none of them is actually set to true, but we can't know why without the rest of your code
<thizanne>
(or maybe you don't actually reach the case where all are false ? The first one looks similar, are you sure you do indeed reach the last one ?)
<ruffy_>
Hmmmm but I print one variable afterwards and it is set to true....
<ruffy_>
Yes I am sure
<ruffy_>
I will look, when the flags are set
<thizanne>
print your variable before the match then
<thizanne>
let decide_algebra = print_bool !flags.supposedtobetrue; match ...
<ruffy_>
Okay I will do that
<ruffy_>
btw, can I open a local module?
<thizanne>
yes
<thizanne>
let open M in ...
<thizanne>
(it's a local open)
<ruffy_>
thank you
<thizanne>
ruffy_: if you could show a minimal example of why it doesn't work, we could help
<ruffy_>
thizanne: I will try that with printing and if it does not help, then I use a pastebin with an example :)
<Armael>
AltGr: does opam-file-format handle both opam1 and opam2 file formats?
Denommus has joined #ocaml
<ruffy_>
thizanne: I have figured out the problem. I had my function on the top level, but called it local in a function afterwards. BUT my top level function has no arguments, so it was evaluated before the call in the function.
<ruffy_>
And the flags were set in the function afterwards. Thank you for the help.
<thizanne>
that's what I thought
<thizanne>
I'm glad you figured that alone, I wasn't sure how to explain in an understandable way without seeing your code
<ruffy_>
thanks again
FreeBirdLjj has joined #ocaml
FreeBirdLjj has quit [Remote host closed the connection]
FreeBirdLjj has joined #ocaml
pierpal has quit [Quit: Poof]
pierpal has joined #ocaml
clownpriest has joined #ocaml
al-damiri has joined #ocaml
freyr69 has quit [Remote host closed the connection]
lobo has quit [Quit: WeeChat 1.6]
sagotch has quit [Quit: Leaving.]
lobo has joined #ocaml
ollehar has quit [Ping timeout: 252 seconds]
jao has joined #ocaml
jbrown has joined #ocaml
Haudegen has quit [Remote host closed the connection]
Fare has joined #ocaml
gareppa has joined #ocaml
clownpriest has quit [Ping timeout: 252 seconds]
tokomak has joined #ocaml
jnavila has joined #ocaml
Fare has quit [Ping timeout: 245 seconds]
bartholin has joined #ocaml
thomas_scrace has quit [Ping timeout: 252 seconds]
Fare has joined #ocaml
clownpriest has joined #ocaml
Haudegen has joined #ocaml
steenuil_ has joined #ocaml
steenuil has quit [Ping timeout: 240 seconds]
Armael has quit [Ping timeout: 250 seconds]
jnavila has quit [Ping timeout: 252 seconds]
gikiam has quit [Ping timeout: 244 seconds]
Armael has joined #ocaml
gikiam has joined #ocaml
jnavila has joined #ocaml
<flux[m]>
ruffy_: there's also the shortcut M.(expr) for short stuff
clownpri1 has joined #ocaml
clownpriest has quit [Ping timeout: 252 seconds]
FreeBirdLjj has quit [Remote host closed the connection]
<discord>
<Perry> Explaining that || is valid and | isn't would be interesting. I presume the grammar in the manual isn't quite valid...
<_y>
Perry, my guess is that | should have the same status as # in infix-symbol (the first url i gave), that is, they must be followed by at least one operator-char
<discord>
<Perry> Ah, I suppose it is covered by this rule: "The following character sequences are also keywords"
<discord>
<Perry> and | is listed there.
<discord>
<Perry> Perhaps text should be added saying that operators are sequences of those characters that are NOT in the set of keywords.
mengu has quit [Ping timeout: 252 seconds]
<_y>
Perry, that is not true, ( & ), ( && ), ( != ), ( + ), ( - ) and so on, are valid operator names
sagotch1 has quit [Quit: Leaving.]
Jesin has joined #ocaml
<discord>
<Perry> ah.
<discord>
<Perry> Then I suppose I don't know what the rule is. 😦
clownpri1 has quit [Ping timeout: 252 seconds]
gareppa has quit [Quit: Leaving]
pierpa has joined #ocaml
TheRuralJuror has joined #ocaml
kakadu has joined #ocaml
clownpri1 has joined #ocaml
TheRuralJuror has quit [Read error: Connection reset by peer]
kotrcka has joined #ocaml
clownpriest has joined #ocaml
clownpri1 has quit [Ping timeout: 252 seconds]
clownpriest has quit [Ping timeout: 240 seconds]
clownpri1 has joined #ocaml
mengu has joined #ocaml
thomas_scrace has joined #ocaml
clownpriest has joined #ocaml
clownpriest has quit [Client Quit]
<discord>
<Perry> I imagine (;) isn't valid either for example, but I don't know what's correct. _y, you should indeed file a bug report.
clownpri1 has quit [Ping timeout: 250 seconds]
clownpriest has joined #ocaml
clownpriest has quit [Client Quit]
clownpriest has joined #ocaml
mengu has quit [Quit: Leaving...]
clownpriest has quit [Client Quit]
clownpriest has joined #ocaml
erkin has joined #ocaml
bartholin has quit [Remote host closed the connection]
gareppa has joined #ocaml
clownpriest has quit [Client Quit]
erkin has quit [Read error: Connection reset by peer]
clownpriest has joined #ocaml
clownpriest has quit [Client Quit]
clownpriest has joined #ocaml
Fare has quit [Ping timeout: 272 seconds]
gareppa has quit [Quit: Leaving]
xuanrui has joined #ocaml
<orbifx>
For binding to C, has there been anything better other than using OCaml's externs and writing stubs?
<orbifx>
I recall something about defining the stubs from within OCaml.. ?
jnavila has quit [Ping timeout: 246 seconds]
erkin has joined #ocaml
<copy`>
orbifx: I haven't used it, but there's ctypes
erkin has quit [Remote host closed the connection]
<Leonidas>
yes, I think ctypes can also create stubs, but it is a bit tricky to get the whole setup to compile
clownpriest has quit [Ping timeout: 240 seconds]
<orbifx>
I see, I remember Ctype as a package for defining C structures. It can also make the stubs?
spew has quit []
<Armael>
yes it can
<orbifx>
copy`, Leonidas anything else? (checking to see if anhything has changed since I looked into this about a year ago)
<orbifx>
thanks Armael
<orbifx>
I remeber there being a performance penalty for unpacking OCaml values from withing OCaml, is that the case?
<Armael>
um, I'm not sure, but I think when using stub generation there should be no runtime penalty compared to manually written stubs
thomas_scrace has quit [Ping timeout: 245 seconds]
thomas_scrace has joined #ocaml
<orbifx>
hmm that's surprising, pleasantly. Would have expected doing more work would lead to something more efficient. Armael
gtrak has quit [Ping timeout: 252 seconds]
kakadu has quit [Remote host closed the connection]
<Armael>
I don't know if ctypes qualifies as "less work" actually, since the more complicated build setup also has its cost
<Armael>
what you gain for sure is safety (and you lose some flexibility, which is fine for most use cases)
<Armael>
(especially with stubs gen, where you have maximal safety and a maximally complicated build setup)