companion_cube changed the topic of #ocaml to: Discussion about the OCaml programming language | http://www.ocaml.org | OCaml 5.2.0 released: https://ocaml.org/releases/5.2.0 | Try OCaml in your browser: https://try.ocamlpro.com | Public channel logs at https://libera.irclog.whitequark.org/ocaml/
leonardus has joined #ocaml
chiselfuse has quit [Read error: Connection reset by peer]
chiselfuse has joined #ocaml
<discocaml> <limp.biskit> what proportion of libraries do you think build without unix
oriba has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
szkl has joined #ocaml
waleee has quit [Ping timeout: 268 seconds]
troydm has quit [Ping timeout: 268 seconds]
szkl has quit [Quit: Connection closed for inactivity]
pi3ce has quit [Quit: No Ping reply in 180 seconds.]
pi3ce has joined #ocaml
leonardus has quit [Quit: Connection closed for inactivity]
chiselfuse has quit [Remote host closed the connection]
chiselfuse has joined #ocaml
mbuf has joined #ocaml
leah2 has quit [Ping timeout: 260 seconds]
bartholin has joined #ocaml
leah2 has joined #ocaml
Tuplanolla has joined #ocaml
ansiwen has quit [Ping timeout: 260 seconds]
ansiwen has joined #ocaml
Serpent7776 has joined #ocaml
tremon has joined #ocaml
pie_ has quit []
pie_ has joined #ocaml
ocra8 has quit [Quit: WeeChat 4.2.2]
<discocaml> <limp.biskit> wow stdlib String sucks
Serpent7776 has quit [Ping timeout: 240 seconds]
infinity0 has quit [Remote host closed the connection]
infinity0 has joined #ocaml
ocra8 has joined #ocaml
troydm has joined #ocaml
<discocaml> <pigeon.v> why?
<discocaml> <limp.biskit> very few easy functions for basic stuff like splitting/trimming
<discocaml> <limp.biskit> CCString is excellent, but sometimes i don’t want to depend on containers for one module
<discocaml> <dra27.> https://ocaml.org/p/astring/latest ?
<discocaml> <limp.biskit> erratique seems to have something for everything
<discocaml> <dra27.> 🙂
<discocaml> <pigeon.v> yah, you can only trim whitespace and split on a single ASCII character...
<discocaml> <pigeon.v> yeah, you can only trim whitespace and split on a single ASCII character...
<discocaml> <limp.biskit> too many operations need you to perform math against length for simple things
<companion_cube> splitting on more chars is indeed annoying
<discocaml> <limp.biskit> e.g dropping a prefix
<companion_cube> I mean, it all boils down to having substring search
<discocaml> <limp.biskit> do you know if theres a way in astring to drop a prefix if matched? e.g. with prefix "abc": "abcdef" becomes "def" but "foobar" is unchanged
<discocaml> <limp.biskit> one line
<discocaml> <smondet> (Base has `String.chop_prefix_if_exists`)
<discocaml> <limp.biskit> yeah, but base is heavy :/
ansiwen has quit [Ping timeout: 260 seconds]
ansiwen has joined #ocaml
<discocaml> <limp.biskit> which is a shame because i do really love their string api
ansiwen has quit [Ping timeout: 240 seconds]
ansiwen has joined #ocaml
ansiwen has quit [Quit: ZNC 1.7.1 - https://znc.in]
ansiwen has joined #ocaml
ansiwen has quit [Ping timeout: 252 seconds]
ansiwen has joined #ocaml
<companion_cube> CCString has that :p
<discocaml> <ozzieshazam> Hi! I'm trying to get vscode integration with ocaml. I am using the [Core.Command] module and `$dune build` works fine but my ocamlformat fails due to using the custom ppx in it
<discocaml> <ozzieshazam>
<discocaml> <ozzieshazam> `Uninterpreted extension 'map_open'.`
pi3ce_ has joined #ocaml
pi3ce has quit [Ping timeout: 268 seconds]
Serpent7776 has joined #ocaml
troydm has quit [Ping timeout: 268 seconds]
hannes has quit [Remote host closed the connection]
mbuf has quit [Quit: Leaving]
gooby323 has joined #ocaml
hannes has joined #ocaml
gooby323 has quit [Ping timeout: 264 seconds]
waleee has joined #ocaml
<discocaml> <limp.biskit> rewrote and functorized my very wip web framework
<discocaml> <limp.biskit> best feeling hello world ever
<discocaml> <limp.biskit> works on httpaf-eio currently, going to port to httpcats
m5zs7k has quit [Ping timeout: 268 seconds]
m5zs7k has joined #ocaml
Serpent7776 has quit [Ping timeout: 240 seconds]
troydm has joined #ocaml
jabuxas has joined #ocaml
<discocaml> <johnkraiven> can anyone here redirect me to the place within the documentation where the `?`, operator I shall assume, as seen in this snippet is described
<discocaml> <johnkraiven> ```ocaml
<discocaml> <johnkraiven> let render ?(syntax_highlighting = false) doc =
<discocaml> <johnkraiven> ```
<discocaml> <limp.biskit> it's an optional labeled argument
<discocaml> <limp.biskit> https://ocaml.org/docs/labels
<discocaml> <limp.biskit> there it will be false unless you pass `~syntax_highlighting:true`, without a default it would be an option thats None if no value is provided
<discocaml> <johnkraiven> got it, thanks a lot @limp.biskit for your time and expertise
bartholin has quit [Quit: Leaving]
<discocaml> <acheac> is there a way to save the expression as a parameter?
<discocaml> <._null._> What do you mean?
jabuxas has quit [Quit: oops :p]
<discocaml> <acheac> i have a homework which is implemeting a method for tree
<discocaml> <acheac> we
<discocaml> <acheac> sm like this
<discocaml> <acheac> we can go left/right
<discocaml> <acheac> or go up
<discocaml> <acheac> i know how to go left right from the root
<discocaml> <acheac> but when i go up
<discocaml> <acheac> but idk how i can go up after
<discocaml> <acheac> so i think i can save a copy of the expression in left/right and whenever up is called, i can goes back to that copy
jabuxas has joined #ocaml
<discocaml> <._null._> And what's your issue?
Tuplanolla has quit [Quit: Leaving.]
<discocaml> <limp.biskit> can you not create an algebraic type representing Null for nodes or top level and an (up, left, right) tuple otherwise
<discocaml> <._null._> That sounds like a zipper, which is not needed if the tree is not modified
<discocaml> <acheac> ye i just other guy, and he told me to look at zipper😂
<discocaml> <._null._> You just need an ancestry list
<discocaml> <acheac> ye i just ask other guy, and he told me to look at zipper😂
<discocaml> <._null._> Oh, so you need modifications. Then go for a zipper, that's their whole purpose
<discocaml> <acheac> ok
<discocaml> <acheac> reading stuff about it rn
<discocaml> <acheac> a bit confused thogh
<discocaml> <acheac> a bit confused though
tremon has quit [Quit: getting boxed in]