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
<d_bot> <rgrinberg> If you're only interested errors, you can also do $ dune build check
mxns has joined #ocaml
mxns has quit [Ping timeout: 246 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 272 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 244 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 256 seconds]
seastack has joined #ocaml
mxns has joined #ocaml
mxns has quit [Ping timeout: 272 seconds]
<Boarders> what does this sort of error mean
mxns has joined #ocaml
reynir has quit [Ping timeout: 240 seconds]
reynir has joined #ocaml
mxns has quit [Ping timeout: 264 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 244 seconds]
Hrundi_V_Bakshi has quit [Ping timeout: 260 seconds]
mfp has quit [Ping timeout: 256 seconds]
h11 has quit [Changing host]
h11 has joined #ocaml
h11 has joined #ocaml
h11 has quit [Quit: authenticating]
h11 has joined #ocaml
Haudegen has quit [Ping timeout: 260 seconds]
amiloradovsky has quit [Ping timeout: 244 seconds]
vicfred has quit [Quit: Leaving]
nicoo has quit [Ping timeout: 240 seconds]
nicoo has joined #ocaml
osa1 has joined #ocaml
borne has quit [Ping timeout: 244 seconds]
borne has joined #ocaml
Jesin has quit [Ping timeout: 256 seconds]
borne has quit [Ping timeout: 264 seconds]
sm2n_ has joined #ocaml
sm2n has quit [Ping timeout: 268 seconds]
sm2n has joined #ocaml
sm2n_ has quit [Ping timeout: 256 seconds]
ggole has joined #ocaml
pyx has joined #ocaml
pyx has quit [Client Quit]
narimiran has joined #ocaml
mxns has joined #ocaml
mxns has quit [Ping timeout: 272 seconds]
kmwyard has joined #ocaml
Jesin has joined #ocaml
cantstanya has quit [Remote host closed the connection]
mbuf has joined #ocaml
cantstanya has joined #ocaml
waleee-cl has quit [Quit: Connection closed for inactivity]
sagax has joined #ocaml
Serpent7776 has joined #ocaml
tane has joined #ocaml
borne has joined #ocaml
mbuf has quit [Ping timeout: 264 seconds]
madroach has joined #ocaml
steenuil has joined #ocaml
ansiwen[m] has quit [Quit: Idle for 30+ days]
<d_bot> <ostera> Boarders: these would be syntax errors and type-errors
<d_bot> <ostera> (possibly also dune-related errors)
bartholin has joined #ocaml
Haudegen has joined #ocaml
mfp has joined #ocaml
bartholin has quit [Quit: Leaving]
DanC has quit [Ping timeout: 264 seconds]
hnOsmium0001 has quit [Quit: Connection closed for inactivity]
DanC has joined #ocaml
mxns has joined #ocaml
narimiran has quit [Ping timeout: 258 seconds]
mxns has quit [Ping timeout: 272 seconds]
narimiran has joined #ocaml
oznt has joined #ocaml
<oznt> hi guys, I am trying to build csexp-1.3.2 on a gentoo system, but I am seeing an error: https://pastebin.com/cAv4sU9R
<oznt> can someone give me a hand please?
<octachron> this sounds like a packaging issue from gentoo's result package. Did you try to upgrade the result package to 1.5 as suggested in gentoo's bug tracker?
<oznt> octachron, no. Thank you
<oznt> that was it
<octachron> great!
jnavila has joined #ocaml
gareppa has joined #ocaml
amiloradovsky has joined #ocaml
gareppa has quit [Remote host closed the connection]
<d_bot> <gar> I need to compile an mli file with a ppx deriving dependency. But if I pass either a cmxa or a cmx I get "don't know what to do with {{file}}". What's the secret formula for this?
<d_bot> <octachron> ppxs are executables, what cmx(a) are you trying to feed this poor ocamlfind with?
Haudegen has quit [Quit: Bin weg.]
<d_bot> <gar> Right, sorry, the problem is a deriver is not getting engaged so when I try to compile the transformed file I get "Cannot locate deriver". That means the ppx is not fully transforming the input, correct? Not that a ppxlib needs to be passed to the compiler...
<d_bot> <gar> This is a locally-defined ppx lib.
<d_bot> <octachron> It sounds more like ppx_deriving had trouble linking the right deriver.
mbuf has joined #ocaml
FreeBirdLjj has joined #ocaml
jnavila has quit [Ping timeout: 272 seconds]
FreeBird_ has joined #ocaml
<d_bot> <gar> yeah, but everything looks in order to (naive) me. The source contains a rewriter (which does get engaged) in one module and a deriver (`Ppxlib.Driver.add deriver...`) in another module. Both modules are passed to the ppx executable compile command, after ppxlib and associated OPAM libs. The rewrite injects `[@@deriving (bin_io, version, sexp)]` . The compiler then complains "Error: Cannot locate deriver version". That's the deri
mbuf has quit [Ping timeout: 246 seconds]
<d_bot> <gar> Or should the ppx executable have transformed the `[@@driving` bit?
FreeBirdLjj has quit [Ping timeout: 256 seconds]
<d_bot> <gar> IOW, there are clearly two passes involved; one injects `[@@deriving`, the other does the derivation. Are they both supposed to happen when I run the ppx executable? BTW, I am running it separately, not passing it to the compiler.
mmohammadi9812 has quit [Ping timeout: 240 seconds]
<d_bot> <gar> My understanding is that In The Beginning multiple jobs were used, but that now `ppxlib` acts as a driver so all passes are handled in one job.
<d_bot> <octachron> If you are invoking directly the ppx, there is no compiler involved.
<d_bot> <octachron> Passing "ppxlib" as a dependency does not make sense?
<d_bot> <octachron> The error is due to ppx_deriving trying to locate the version deriver and failing.
mmohammadi9812 has joined #ocaml
<d_bot> <gar> Since the code contains `Ppxlib.Driver.add ...`, it must be that I'm building the ppx executable incorrectly? I.e. that code is not being called at load time.
jnavila has joined #ocaml
mxns has joined #ocaml
<d_bot> <gar> @octachron I was passing ppxlib to the compile under a delusion.
amiloradovsky has quit [Ping timeout: 244 seconds]
<d_bot> <octachron> By default, derivers are dynamically linked, if you don't give the location of the plugins at when running the ppx_deriving ppx, it can only fail.
<d_bot> <gar> So when I build my ppx lib, emitting a cmxs is a requirement?
<d_bot> <gar> I do put all the locations on the search path using `-I`.
<d_bot> <octachron> Or as stated in the ppx_deriving documentation, you need to build ppx in static mode.
mxns has quit [Ping timeout: 272 seconds]
<d_bot> <octachron> Also are you sure that `-I` is the right flag for ppx_deriving?
<d_bot> <gar> Ok, there must be a problem in my compile command for the executable. I pass all the cmx files, I put everything in the search path, and I use `-linkall`, and the last thing I pass is a module containing only `let () = Ppxlib.Driver.standalone ()`. Anything else I need to do?
amiloradovsky has joined #ocaml
<d_bot> <gar> I also pass `-predicates ppx_driver`, and I use `-linkpkg` and `-package` for OPAM deps.
jnavila has quit [Ping timeout: 256 seconds]
tvn948 has joined #ocaml
Haudegen has joined #ocaml
tvn948 has quit [Ping timeout: 240 seconds]
<d_bot> <octachron> That doesn't seem obviously wrong.
mmohammadi9812 has quit [Ping timeout: 246 seconds]
nullcone has quit [Quit: Connection closed for inactivity]
thizanne has quit [Ping timeout: 246 seconds]
artart78 has quit [Ping timeout: 244 seconds]
Fardale has quit [Ping timeout: 260 seconds]
jun has quit [Ping timeout: 272 seconds]
thizanne has joined #ocaml
mmohammadi9812 has joined #ocaml
<d_bot> <gar> The error message `Cannot locate deriver` - is that emitted by the compiler or by something from `ppxlib`? I would think the compiler, but how does it know about `deriver`?
Fardale has joined #ocaml
jun has joined #ocaml
artart78 has joined #ocaml
mmohammadi9812 has quit [Ping timeout: 240 seconds]
nicoo has quit [Remote host closed the connection]
nicoo has joined #ocaml
mmohammadi9812 has joined #ocaml
Tuplanolla has joined #ocaml
jnavila has joined #ocaml
<d_bot> <gar> Ok, I see what the problem is. For some OPAM deps, `ocamlfind` injects `-ppx` options into the command line. That works for the OPAM stuff since it follows `findlib` conventions. My locally-defined ppxlib does not. Don't know that the solution is yet, but that's where the problem lies. Thanks for your feedback @octachron
Serpent7776 has quit [Read error: Connection reset by peer]
Serpent7776 has joined #ocaml
FreeBird_ has quit [Remote host closed the connection]
waleee-cl has joined #ocaml
amiloradovsky has quit [Ping timeout: 260 seconds]
mxns has joined #ocaml
amiloradovsky has joined #ocaml
<d_bot> <octachron> The cannot locate deriver error message is raised by ppx_deriving (borrowing the error printing API from the compiler), the compiler is not involved at all.
vicfred has joined #ocaml
steenuil has quit [Read error: Connection reset by peer]
steenuil has joined #ocaml
reynir has quit [Ping timeout: 240 seconds]
<d_bot> <vinz> is there a way to ask ocamlopt to keep the `/tmp/foo.o` file it generates on calls like `as -o 'src/.foo_objs/native/foo.o' '/tmp/camlasmabef9b.s'`
RalfJ has quit [Read error: Connection reset by peer]
hnOsmium0001 has joined #ocaml
reynir has joined #ocaml
RalfJ has joined #ocaml
<def> -S ?
<d_bot> <vinz> will try !
Haudegen has quit [Quit: Bin weg.]
nullcone has joined #ocaml
mxns has quit [Ping timeout: 244 seconds]
mxns has joined #ocaml
borne has quit [Ping timeout: 244 seconds]
tane has quit [Quit: Leaving]
amiloradovsky has quit [Remote host closed the connection]
amiloradovsky has joined #ocaml
<d_bot> <gar> @octachron Turns out there is an error in my code for handling transitive deps. It resulted in a ppx being passed as a dep for the compile, which in turn caused ocamlfind to inject a `-ppx` option that introduced ppx_deriving, which in turn received control from the compiler when the deriving attribute needed handling, so of course it could not find the deriver. I guess deriving attrs do not need to be expanded in mli files?
<d_bot> <octachron> No they need to be expanded in mli files to expose the derived functions
Haudegen has joined #ocaml
artart78 has quit [Changing host]
artart78 has joined #ocaml
<d_bot> <Skilly> i have a question about menhir and shift/reduce conflicts - inlined it with the code snippets here because i'm not sure how the irc bot would like this https://hashb.in/#JYAgFghgbgpiAOAnA9gIwqgNgTxBEAzsJjiAI4CuMBALsMgHZ6rIU0gCyMDYwiCEREQYBzPAwAmhXgDMaAekQwJFAMZxVjGZmCqaBADQhUbcDCUhg7EcmoAuAFAPNDGjAAeNOyAcADfzTYjiAgAD4gACoAkgByESEgAN6RUa4gAL4OIeERAEIA8vkAMiHJecjImBlZYSCIALyIgfBJkQBKMDJ1GSD+vk4AtrhIaJgwA94OwF1RIB7wOqpWMKSQsClx8nmFJT
<d_bot> <Skilly> oops, didn't realise how long that link is, sorry
<d_bot> <Skilly> thinking about this some more - i think it has to do with the fact that while it could resolve it if it had more lookahead tokens, it can't right now because it needs to make the decision about "do i use `ty` or do I use TINT/TBOOL" - is that remotely correct?
<d_bot> <Skilly> (and therefore, replacing the explicit TINT/TBOOL's with `ty` makes it so the parser doesn't have to worry about this decision yet, and only make this decision once it reaches RBRACKET vs `exp`, an unambiguous choice)
<d_bot> <octachron> Indeed, you also inline ty to avoid the issue.
vicfred has quit [Quit: Leaving]
vicfred has joined #ocaml
<d_bot> <Skilly> @octachron as in `%inline ty` is another option? or what does that mean?
<d_bot> <octachron> %inline ty is another option. There is a nice explanation in menhir manual but basically, the option inlines in place the "inline" rule, which provides more context to make shift and reduce decisions.
berberman_ has quit [Ping timeout: 272 seconds]
berberman has joined #ocaml
Hrundi_V_Bakshi has joined #ocaml
<d_bot> <Skilly> thank you!
osa1 has quit [Ping timeout: 246 seconds]
borne has joined #ocaml
mxns has quit [Ping timeout: 260 seconds]
mxns has joined #ocaml
averell has quit [Quit: .]
averell has joined #ocaml
<mrvn> Skilly: Most parsers only use one token lookahead. So the next token must be sufficient to pick up which rule to follow. Most parsers loosen that though, e.g. keep going till they have the longest match.
<mrvn> Makes things like "if <expr> then <statement>" and "if <expr> then <statement> else <statement>" possible.
narimiran has quit [Ping timeout: 256 seconds]
amiloradovsky has quit [Remote host closed the connection]
amiloradovsky has joined #ocaml
ggole has quit [Quit: Leaving]
borne has quit [Ping timeout: 272 seconds]
borne has joined #ocaml
jnavila has quit [Quit: Konversation terminated!]
zebrag has joined #ocaml
inkbottle has quit [Ping timeout: 256 seconds]
mrvn has quit [Ping timeout: 260 seconds]
mrvn has joined #ocaml
borne has quit [Quit: WeeChat 2.9]
mxns has quit [Ping timeout: 256 seconds]
mxns has joined #ocaml
mxns has quit [Ping timeout: 264 seconds]
wingsorc has joined #ocaml