wbooze has quit [Remote host closed the connection]
bartholin has joined #ocaml
wbooze has joined #ocaml
Serpent7776 has joined #ocaml
sailorCat has quit [Ping timeout: 252 seconds]
sailorCat has joined #ocaml
dreadedfrog has joined #ocaml
toastal has quit [Ping timeout: 256 seconds]
dreadedfrog has quit [Ping timeout: 256 seconds]
toastal has joined #ocaml
pi3ce_ has quit [Ping timeout: 256 seconds]
pi3ce has joined #ocaml
mbuf has joined #ocaml
wbooze has quit [Remote host closed the connection]
wbooze has joined #ocaml
wbooze has quit [Ping timeout: 268 seconds]
myrkraverk__ has joined #ocaml
myrkraverk_ has quit [Read error: Connection reset by peer]
wbooze has joined #ocaml
Inline has joined #ocaml
toastal has left #ocaml [Disconnected: Hibernating too long]
<discocaml_>
<regularspatula> Does anyone know the rationale behind not including the name in the element end tags in the xmlm library (pull based XML library)? Perhaps for increased performance?
<discocaml_>
<regularspatula> for comparison, I was doing a bit of a look at some other pull based XML parsers in other languages and they all seem to include the name in the element end signals
<discocaml_>
<limp.biskit> why does Uri.query give a (string * string list) list
<discocaml_>
<limp.biskit> the inner list always seems to contain one element even with duplicate keys
<discocaml_>
<limp.biskit> is there some parsing on the value itself i’m unaware of?
<discocaml_>
<deepspacejohn> I can only guess the specific rationale that the xmlm authors had, but including the name in the end tag is arguably just extra information with no real benefit. If you wanted to validate that they match start tags, then you have to do that at runtime.
<discocaml_>
<regularspatula> Yeah that is what I always assumed as well. But looking at some other pull-based parsers got me wondering if my assumptions were reasonable
pi3ce has quit [Quit: No Ping reply in 180 seconds.]
pi3ce has joined #ocaml
toastal has joined #ocaml
<discocaml_>
<leviroth> It will split on commas I believe
toastal has left #ocaml [Error from remote client]
Tuplanolla has joined #ocaml
mbuf has quit [Quit: Leaving]
reynir has quit [Quit: WeeChat 3.0]
reynir has joined #ocaml
<discocaml_>
<kakadu18> I'm looking at qcheck library, and I want to generate identifiers, which are not keywords. I was expecting `QCheck.Gen.filter` or similar function, but it is not there. I was going to fix this using bind, but I can't find obvious empty generator either. Any advice?
<companion_cube>
There's assuming and the likes, but ideally you'd avoid filtering out bad values, it carries a risk of non termination
<companion_cube>
(what if invalid values are a lot more likely than valid values?)
Inline has quit [Remote host closed the connection]
Inline has joined #ocaml
wbooze has quit [Remote host closed the connection]
Anarchos has joined #ocaml
Inline has quit [Quit: Leaving]
wbooze has joined #ocaml
Serpent7776 has quit [Ping timeout: 256 seconds]
<discocaml_>
<kakadu18> Yes, in the ideal situation I need to make prefix tree of my keyword, and modify generation of the next character in the identifier to avoid generation of a keyword. But what about quick and dirty solution?
<companion_cube>
Ah if it's sparse, ok I guess
<companion_cube>
Just use assume to filter out the test case
<discocaml_>
<kakadu18> But 'assume' leads to slow generate&filter approach. Any better solution?
bartholin has quit [Quit: Leaving]
<discocaml_>
<sim642> What are you actually trying to quickcheck though? Maybe you can just generate names of some specific form that definitely isn't a keyword
<discocaml_>
<kakadu18> That parsing after pretty-printing is identity. Yes, I'm looking for short way to generate identifiers, that are not in the small predefined list of keywords.
<discocaml_>
<limp.biskit> cool. is that a part of the RFC?
<discocaml_>
<leviroth> As far as I could tell it is not
<discocaml_>
<leviroth> I don't even think the key=value thing is really part of the rfc
Tuplanolla has quit [Quit: Leaving.]
<discocaml_>
<limp.biskit> ah
<discocaml_>
<limp.biskit> odd
<discocaml_>
<limp.biskit> don’t think i’ve seen the comma separated syntax
<discocaml_>
<limp.biskit> i have seen duplicate keys in the wild
<discocaml_>
<anmonteiro> the actual reason is because you can duplicate keys `?foo=bar&foo=baz`