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
Jesin has quit [Ping timeout: 240 seconds]
<d_bot> <inkbottle> "esy": {
<d_bot> <inkbottle> "build": "dune build -p #{self.name}"
<d_bot> <inkbottle> },
<d_bot> <inkbottle> "scripts": {
<d_bot> <inkbottle> "test": "esy x hello_world"
<d_bot> <inkbottle> },```
<d_bot> <inkbottle> and added `(public-name hello_world)` to the dune file in `example/hello_world`.
<d_bot> <inkbottle>
<d_bot> <inkbottle> But trying to build it, or execute it with `esy test` raises error: `Error: I can't determine automatically which package this stanza is for.` So I've added `(package opium)` but then I get `Error: Library "ppx_yojson_conv" not found.` because of course it is not in the dependencies of opium as declared in `dune-project` file.
<d_bot> <inkbottle> I'm wondering what would be the best way to build the example (hello_world) in that setting.
dhil has quit [Ping timeout: 260 seconds]
Haudegen has quit [Ping timeout: 272 seconds]
<d_bot> <inkbottle> Also, is the line:
<d_bot> <inkbottle> ```json
<d_bot> <inkbottle> "build": "dune build -p #{self.name}"
<d_bot> <inkbottle> ```
<d_bot> <inkbottle> used at all?
<d_bot> <inkbottle> And isn't the project already build just thorough the `package.json` file `dependencies` and `resolutions` stanza?
FreeBirdLjj has joined #ocaml
<d_bot> <inkbottle> For the example building part:
<d_bot> <inkbottle> ```bash
<d_bot> <inkbottle> esy b dune build ./example/hello_world/main.exe
<d_bot> <inkbottle> esy b dune exe ./example/hello_world/main.exe
<d_bot> <inkbottle> ```
<d_bot> <inkbottle> Work just fine.
<d_bot> <inkbottle> And I introduced an error in `app.ml` and the command `esy` reports it and fails, so it really is using and building the locally cloned project.
<d_bot> <inkbottle> And I thing the line
<d_bot> <inkbottle> ```json
<d_bot> <inkbottle> "build": "dune build -p #{self.name}"
<d_bot> <inkbottle> ```
<d_bot> <inkbottle> isn't used, here.
<d_bot> <rgrinberg> @poogle 1.5.1 should be published shortly.
<d_bot> <poogle> @rgrinberg that's great stuff.
Tuplanolla has quit [Quit: Leaving.]
sm2n has quit [Read error: Connection reset by peer]
borne has quit [Ping timeout: 264 seconds]
<d_bot> <darrenldl> in general do people find qcheck sufficient (to whatever standard they have) and call it there? or should all property tests move to fuzzing eventually?
sm2n has joined #ocaml
<companion_cube> Not sure if you'd run fuzzing in CI
<d_bot> <theangryepicbanana> Is there a non-greedy version of `separated_nonempty_list` in Menhir?
<d_bot> <theangryepicbanana> I would like to be able to match `a b c` and `a b d` (two separate rules) within the same rule
webshinra has quit [Read error: Connection reset by peer]
<d_bot> <theangryepicbanana> however, it considers `a b d` a syntax error because it's trying to match `a b c` instead (and failing)
mfp has quit [Ping timeout: 246 seconds]
webshinra has joined #ocaml
<d_bot> <darrenldl> companion_cube: well okay fair, still need the qcheck tests for CI. say qcheck is a necessity in that sense, would you also (always) add fuzzing on top of it?
<companion_cube> I confess I never used fuzzing
<companion_cube> It can be a good practice if you write internet facing parsers
<d_bot> <darrenldl> i was using crowbar for some parts that take too long for qcheck, then began thinking if i actually need/want fuzzing for all other property tests currently done in qcheck
<d_bot> <darrenldl> but if containers doesn't use fuzzing (if i'm not misinterpreting your sentence), then qcheck would be good enough standard to me
<companion_cube> Ah, well, it's always a trade-off :)
<companion_cube> If I had the tooling I'd like to, some day, prove some parts of it
<companion_cube> For now it's a dream
madroach_ has joined #ocaml
madroach has quit [Ping timeout: 256 seconds]
steenuil has quit [Read error: Connection reset by peer]
<d_bot> <darrenldl> > If I had the tooling I'd like to, some day, prove some parts of it
<d_bot> <darrenldl> don't we all
mfp has joined #ocaml
Jesin has joined #ocaml
zebrag has quit [Quit: Konversation terminated!]
zebrag has joined #ocaml
mfp has quit [Ping timeout: 246 seconds]
<companion_cube> Gospel might be it some day
madroach has joined #ocaml
madroach_ has quit [Ping timeout: 256 seconds]
urek has quit [Ping timeout: 272 seconds]
Jeanne-Kamikaze has quit [Quit: Leaving]
tryte has quit [Remote host closed the connection]
tryte has joined #ocaml
vesper11 has quit [Quit: ZNC 1.7.5 - https://znc.in]
vesper11 has joined #ocaml
vicfred has quit [Quit: Leaving]
aaaaaa has joined #ocaml
vesper has joined #ocaml
vesper11 has quit [Ping timeout: 264 seconds]
amiloradovsky has quit [Remote host closed the connection]
narimiran has joined #ocaml
mrvn has quit [Ping timeout: 256 seconds]
mrvn has joined #ocaml
aaaaaa has left #ocaml [#ocaml]
mxns has quit [Ping timeout: 272 seconds]
waleee-cl has quit [Quit: Connection closed for inactivity]
<d_bot> <Ulugbek> whoops, sorry 😦
mxns has joined #ocaml
mxns has quit [Ping timeout: 240 seconds]
<d_bot> <rgrinberg> No worries. Happens to everybody.
mbuf has joined #ocaml
vicfred has joined #ocaml
mbuf has quit [Remote host closed the connection]
mbuf has joined #ocaml
garfr has quit [Ping timeout: 272 seconds]
decentpenguin has quit [Quit: ZNC crashed or something]
decentpenguin has joined #ocaml
shawnw has joined #ocaml
snowpanda has joined #ocaml
<snowpanda> On this page https://www.cs.cornell.edu/courses/cs3110/2020sp/textbook/modules/encapsulation_includes.html, what does module ListSetDups : Set = ListSetDupsImpl do?
<d_bot> <Ulugbek> `module M = N` says that you can use handle `M` to refer to module `N`
<d_bot> <Ulugbek> `module M: T = N` says that you can use handle `M` to refer to module `N` but `M` should have interface of module type `T`
<d_bot> <Ulugbek>
<d_bot> <Ulugbek> ```
<d_bot> <Ulugbek> ─( 12:46:49 )─< command 0 >──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
<d_bot> <Ulugbek> utop # module Impl = struct let f x = x end;;
<d_bot> <Ulugbek> module Impl : sig val f : 'a -> 'a end
<d_bot> <Ulugbek> ─( 12:46:50 )─< command 1 >──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
<d_bot> <Ulugbek> utop # module type T = sig val f : int -> int end;;
<d_bot> <Ulugbek> module type T = sig val f : int -> int end
<d_bot> <Ulugbek> ─( 12:47:15 )─< command 2 >──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
<d_bot> <Ulugbek> utop # module I = Impl;;
<d_bot> <Ulugbek> module I = Impl
<d_bot> <Ulugbek> ─( 12:47:37 )─< command 3 >──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
<d_bot> <Ulugbek> utop # #show I;;
<d_bot> <Ulugbek> module I = Impl
<d_bot> <Ulugbek> module I : sig val f : 'a -> 'a end
<d_bot> <Ulugbek> ─( 12:47:48 )─< command 4 >──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
<d_bot> <Ulugbek> utop # module I : T = Impl;;
<d_bot> <Ulugbek> module I : T
<d_bot> <Ulugbek> ─( 12:47:52 )─< command 5 >──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
<d_bot> <Ulugbek> utop # #show I;;
<d_bot> <Ulugbek> module I : T
<d_bot> <Ulugbek> ```
zebrag has quit [Quit: Konversation terminated!]
zebrag has joined #ocaml
Haudegen has joined #ocaml
vodkaInferno has joined #ocaml
vicfred has quit [Quit: Leaving]
vodkaInf1rno has quit [Ping timeout: 260 seconds]
kini has quit [Read error: Connection reset by peer]
wagle has quit [Ping timeout: 260 seconds]
wagle has joined #ocaml
kini has joined #ocaml
mbuf has quit [Ping timeout: 256 seconds]
snowpanda has quit [Quit: Leaving...]
lizzin has quit [Ping timeout: 246 seconds]
hnOsmium0001 has quit [Quit: Connection closed for inactivity]
borne has joined #ocaml
lizzin has joined #ocaml
lizzin is now known as Guest85957
olle has joined #ocaml
bartholin has joined #ocaml
Guest85957 has quit [Ping timeout: 256 seconds]
urek has joined #ocaml
lizzin_ has joined #ocaml
lizzin_ has quit [Ping timeout: 256 seconds]
mfp has joined #ocaml
rockethead has joined #ocaml
rockethead has quit [Remote host closed the connection]
steenuil has joined #ocaml
berberman_ has joined #ocaml
berberman has quit [Ping timeout: 272 seconds]
ggole has joined #ocaml
lizzin has joined #ocaml
lizzin is now known as Guest88032
Haudegen has quit [Quit: Bin weg.]
nullcone has quit [Quit: Connection closed for inactivity]
dhil has joined #ocaml
urek__ has joined #ocaml
urek has quit [Ping timeout: 246 seconds]
Guest88032 has quit [Ping timeout: 240 seconds]
urek has joined #ocaml
urek__ has quit [Ping timeout: 246 seconds]
noonien has quit [Ping timeout: 256 seconds]
Haudegen has joined #ocaml
dborisog has joined #ocaml
borne has quit [Ping timeout: 246 seconds]
borne has joined #ocaml
dhil has quit [Ping timeout: 240 seconds]
dborisog has quit [Remote host closed the connection]
dborisog has joined #ocaml
dborisog has quit [Ping timeout: 260 seconds]
<zozozo> is there any way for atdgen to generate code ocaml using regular/normal variants and not polymorphic variants ?
dhil has joined #ocaml
lizzin has joined #ocaml
lizzin is now known as Guest58785
mxns has joined #ocaml
Guest58785 has quit [Ping timeout: 260 seconds]
DanC has quit [Ping timeout: 240 seconds]
DanC has joined #ocaml
mxns has quit [Ping timeout: 246 seconds]
mxns has joined #ocaml
waleee-cl has joined #ocaml
berberman has joined #ocaml
berberman_ has quit [Ping timeout: 272 seconds]
hnOsmium0001 has joined #ocaml
<d_bot> <Christophe> zozozo
<zozozo> @Christophe : thanks, ^^
Anarchos has joined #ocaml
<Anarchos> is there a reentrant version of Format.str_formatter ?
<theblatte> Anarchos: not sure if it's reentrant but there's Format.asprintf to format into a string too
<d_bot> <rgrinberg> Or `Format.formatter_of_buffer` and then go from there.
<Anarchos> i will look for it rgrinberg
<Anarchos> theblatte ok thanks
Anarchos has quit [Quit: Vision[0.10.3]: i've been blurred!]
lizzin has joined #ocaml
bartholin has quit [Quit: Leaving]
lizzin is now known as Guest68890
Guest68890 has quit [Ping timeout: 256 seconds]
<zozozo> is there a way for dune to promote files after pre-processing (so that the code generated by the ppx is actually committed or at least inspectable) ?
<theblatte> you can add a ppx directive that will be replaced by the ppx-expanded file but I never remember how to do it
<zozozo> I also remember having used it once, but can't remember it either, XD
shawnw has quit [Ping timeout: 264 seconds]
<zozozo> ah, maybe it's @@@deriving_inline
amiloradovsky has joined #ocaml
ygrek has joined #ocaml
<d_bot> <EduardoRFS> yey the backport got merged \o\
sagax has quit [Remote host closed the connection]
<d_bot> <octachron> I am preparing the 4.10.2 release right now 😄 .
Haudegen has quit [Quit: Bin weg.]
<d_bot> <EduardoRFS> /o/
lizzin has joined #ocaml
lizzin is now known as Guest35866
<d_bot> <tjammer> Hi ocamlers, I could use some advice:
<d_bot> <tjammer> I have written bindings with ctypes (which is excellent btw) and am unsure if I should expose the Ctypes types in my interface. I have some functions which take or return pointers, so I can't hide all of it. I managed to hide most of it using abstract types, but then I needed to put everything into one compilation unit, which somehow feels wrong.
nullcone has joined #ocaml
<d_bot> <tjammer> The main "problem" I have is that the compiler expands the Ctypes types to really long names (`(Vector2.t, [Struct]) Ctypes_static.structured` for example) which becomes unreadable fast. For the documentation I can get around this using substitutions (`type t := Ctypes....`), but for the compiler errors and Tuareg (or ocaml-lsp) they still get expanded. Have I missed any options?
vicfred has joined #ocaml
elfring has joined #ocaml
olle has quit [Ping timeout: 240 seconds]
<d_bot> <octachron> If possible, it is probably better to completely avoid exposing the Ctypes types. Otherwise, you need to rely on the short-paths heuristics which are far from perfect currently.
delysin has quit [Quit: WeeChat 3.0]
delysin has joined #ocaml
Haudegen has joined #ocaml
aterius has left #ocaml ["User left"]
jnavila has joined #ocaml
Tuplanolla has joined #ocaml
<hannes> octachron: since you're preparing the release, it'd be great to have clang11 compatibility there (see https://github.com/ocaml/ocaml/pull/9981)...
<octachron> This bugfix seems fine for 4.11.2 but I would rather not open the floodgate for 4.10.2 . Is there an argument why this bugfix and only this one should be in 4.10 ?
<hannes> octachron: I'm not an OCaml release manager, so it is your call. my intuition/reasoning is as follows: OCaml tries to have their released versions available (compilable) on all tier 1 platforms (this is the reason for 4.10.2 AFAIU)
<hannes> now, FreeBSD/amd64 is a tier1 platform, and ships clang11 -- where no released version compiles out of the box atm
<hannes> but as noted, this was mainly a suggestion/question -- it is fine to do a 4.10.2 as the "macOS/arm64 port" quick-fix-release
<hannes> oh, and now I see that the "-fcommon" thing was manually backported to all ocaml versions and variants in opam repository (to support gcc 10) -- so eventually this is the way to deal with 9981 as well
<hannes> sorry for the noise then
<octachron> On the other hand, fixing the support for a tier 1 platform seems both sound and specific.
urek has quit [Remote host closed the connection]
<octachron> I will sleep on the issue and decide tomorrow.
urek has joined #ocaml
berberman_ has joined #ocaml
berberman has quit [Ping timeout: 268 seconds]
<hannes> hmm, I guess I also didn't understand why there is now a 4.10.2 (and not a 4.11.2 release) with the macos/arm64 PR merged...
<hannes> good news is that 9981 applies cleanly on the 4.10 branch :)
<octachron> For 4.11.2, the idea is to release close to 4.12 to backport the safe bugfixes from the 4.12 ... And somehow people really wanted to have an official 4.10 release on homebrew.
<octachron> Having one exceptional release by new tier 1 platform seemed to be a reasonable frequency for exceptional releases.
<hannes> ok, fair enough :) (and your release work is highly appreciated! thanks!:) now I'm sorry for trying to add more patches to that release
<hannes> s/add/sneak in/
<octachron> Don't feel sorry. On the contrary, thank you for reminding me of the FreeBSD situation. And there is already a cygwin64 patch that has snuck into this release .
urek__ has joined #ocaml
urek has quit [Ping timeout: 246 seconds]
sagax has joined #ocaml
_whitelogger has joined #ocaml
mxns has quit [Ping timeout: 264 seconds]
ggole has quit [Quit: Leaving]
mxns has joined #ocaml
amiloradovsky has quit [Remote host closed the connection]
urek has joined #ocaml
urek__ has quit [Ping timeout: 272 seconds]
urek__ has joined #ocaml
narimiran has quit [Ping timeout: 260 seconds]
mxns has quit [Ping timeout: 246 seconds]
urek has quit [Ping timeout: 272 seconds]
wonko7 has joined #ocaml
mxns has joined #ocaml
mxns has quit [Ping timeout: 240 seconds]
tane has joined #ocaml
borne has quit [Ping timeout: 272 seconds]
stux|RC-- has joined #ocaml
jnavila has quit [Quit: Konversation terminated!]
elfring has quit [Quit: Konversation terminated!]
aspiwack[m] has quit [*.net *.split]
pqwy[m] has quit [*.net *.split]
bjorkint0sh has quit [*.net *.split]
adi__________ has quit [*.net *.split]
stux|RC has quit [*.net *.split]
neiluj has quit [Quit: Lost terminal]
neiluj has joined #ocaml
neiluj has quit [Changing host]
neiluj has joined #ocaml
tane has quit [Quit: Leaving]
adi__________ has joined #ocaml
bjorkint0sh has joined #ocaml
pqwy[m] has joined #ocaml
aspiwack[m] has joined #ocaml
mxns has joined #ocaml
borne has joined #ocaml
stux|RC-- has quit [Quit: Aloha!]
stux|RC has joined #ocaml
urek has joined #ocaml
Guest35866 has quit [Ping timeout: 240 seconds]
urek__ has quit [Ping timeout: 272 seconds]
lizzin has joined #ocaml
lizzin is now known as Guest61250
urek__ has joined #ocaml
urek has quit [Ping timeout: 240 seconds]
mxns_ has joined #ocaml
mxns has quit [Ping timeout: 246 seconds]
mxns_ has quit [Ping timeout: 246 seconds]
Anarchos has joined #ocaml
wonko7 has quit [Ping timeout: 256 seconds]
Guest61250 has quit [Ping timeout: 264 seconds]
Anarchos has quit [Quit: Vision[0.10.3]: i've been blurred!]
Anarchos has joined #ocaml