adrien changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org | OCaml 4.08 release notes: https://caml.inria.fr/pub/distrib/ocaml-4.08/notes/Changes | Try OCaml in your browser: http://try.ocamlpro.com | Public channel logs at http://irclog.whitequark.org/ocaml
pyan has quit [Quit: brb]
pyan has joined #ocaml
liberiga has joined #ocaml
mfp has quit [Ping timeout: 244 seconds]
tormen_ has joined #ocaml
tormen has quit [Ping timeout: 268 seconds]
liberiga has quit [Ping timeout: 260 seconds]
jao- has quit [Ping timeout: 248 seconds]
gravicappa has joined #ocaml
nullifidian__ has joined #ocaml
nullifidian_ has quit [Read error: Connection reset by peer]
liberiga has joined #ocaml
vicfred has quit [Quit: Leaving]
liberiga has quit [Ping timeout: 260 seconds]
mustapha has joined #ocaml
mustapha has left #ocaml [#ocaml]
mustapha has joined #ocaml
<mustapha> Whenever I want to set a breakpoint in the ocaml debugger, it always says that the function identifier is unbound. I'm using `break funcname`, any ideas why?
<mustapha> break @ Module linenum works, but break funcname isn't.
<mustapha> All bytecode is compiled with -g and linked also. I can debug without pb, but it's just this particular command that fails - and I haven't really seen anything on stackoverflow, et al.
mbuf has joined #ocaml
<companion_cube> maybe you need to include the build directory, or something
<Leonidas> companion_cube: oh, a pity. But I can see your point about travel.
<companion_cube> that's the annoying part of living across the ocean :/
<sgnb> rwmjones: virt-top 1.9.0 FTBFS here with "Error: Unbound constructor D.StatsState" in collect.ml... does it ring a bell?
kalio has quit [Ping timeout: 245 seconds]
kalio has joined #ocaml
mustapha has left #ocaml [#ocaml]
jnavila has joined #ocaml
narimiran has joined #ocaml
<sgnb> it was added in https://libvirt.org/git/?p=libvirt-ocaml.git;a=commitdiff;h=652f883f365d8caa7b841b7a3b19a4719402a92f ... ocaml-libvirt definitely needs a new release...
diginet has quit [Quit: diginet has quit!]
ggole has joined #ocaml
<rwmjones> sgnb: oh yes, I think it needs the up to date libvirt-ocaml
<rwmjones> unfortunately I'm not too sure how to make a release of libvirt-ocaml so may be best to temporarily package that one from git
jnavila has quit [Ping timeout: 272 seconds]
Birdface has joined #ocaml
bartholin has quit [Remote host closed the connection]
antron has joined #ocaml
antron has quit [Remote host closed the connection]
<pino|work> Leonidas: i don't have experience with opam, so from my POV you're more than welcome to contribute it
mfp has joined #ocaml
<pino|work> Leonidas: of course, you need to get rwmjones' ack about that
flodin_ has quit [Read error: Connection reset by peer]
mfp has quit [Ping timeout: 258 seconds]
zolk3ri has joined #ocaml
xorpse has quit [Quit: ZNC 1.6.5+deb1+deb9u1 - http://znc.in]
nullifidian__ has quit [Read error: Connection reset by peer]
nullifidian__ has joined #ocaml
Netsu has joined #ocaml
<Netsu> Hello there. Can I constraint function's type parameter?
<esum> yes
kakadu_ has quit [Read error: Connection reset by peer]
<esum> you want to do let f (n : int) = …
<Netsu> like let f : 'a constraint 'a (module Caml.Map.S) -> 'a
<Netsu> esum: oh, maybe you right, it should be simpler :)
kakadu_ has joined #ocaml
<Netsu> but what if I want function of two arguments of same type (I don't know exactly type, but it's certain type which subtype of (module Caml.Map.S))?
<esum> would let f (type a) (x : a) (y : a) work in your situation ?
<Netsu> like `let (type t <: (module Caml.Map.S)) (x : t) (y : t)`?
<Netsu> not exactly ocaml's syntax, but kinda like type constraints from Scala
<Netsu> Ok, even without subtyping, how can I do next without intermediate type? `type 'a t constraint 'a = (module Caml.Map.S);; let f (type t) (x : t) (y : t) : unit = ();;`
<Netsu> well, not exactly what I need, because function should depend not on `t`, but rather on `'a`.
mfp has joined #ocaml
Netsu has quit [Ping timeout: 260 seconds]
freyr69 has joined #ocaml
freyr69 has left #ocaml ["ERC (IRC client for Emacs 27.0.50)"]
freyr69 has joined #ocaml
tane has joined #ocaml
<ggole> let f (x : (module Caml.Map.S) as 'a) (y : 'a) = ..., perhaps
kvda has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Haudegen has joined #ocaml
gravicappa has quit [Ping timeout: 272 seconds]
gravicappa has joined #ocaml
tizoc has quit [Quit: Coyote finally caught me]
tizoc has joined #ocaml
jao has joined #ocaml
kakadu_ has quit [Ping timeout: 245 seconds]
kakadu_ has joined #ocaml
spew has joined #ocaml
Netsu has joined #ocaml
<Netsu> ggole: oh, thank you
<Leonidas> rwmjones: pino|work: https://github.com/ocaml/opam-repository/pull/14715 I just quickly wrote something, let's see if this will work.
<rwmjones> Leonidas: do you actually want to do a "make install"? does that add an implicit DESTDIR?
<Leonidas> rwmjones: I have set `--prefix`, so I assume it will install into the correct ocaml compiler destination?
<rwmjones> ok yes it should do
<pino|work> Leonidas: what about the C dependencies? ie how do you say opam to ensure that the C library (or the non-ocaml requirements, in general) are satisfied?
<pino|work> at least from the failing ci logs, it seems that it is an issue
<Netsu> ggole: from `let f (x : (module Caml.Map.S) as 'a) (y : 'a) = ...` can type k = let module X = (val x) in X.key would be used in such function signature?
<Netsu> kinda first-class-module-dependent type
emias has quit [Ping timeout: 245 seconds]
<Netsu> like in functors F (M : S) (K : sig type t = S.key end)
<Netsu> but for functions and first-class modules
<ggole> I think you probably want Map.S with type key = 'a
monad_cat has quit [Ping timeout: 250 seconds]
alexelcu has quit [Ping timeout: 250 seconds]
nkaretnikov has quit [Ping timeout: 250 seconds]
<Leonidas> pino|work: yeah, I forgot about the dependencies, give me a second :)
robmyers has quit [Ping timeout: 250 seconds]
andreypopp has quit [Ping timeout: 250 seconds]
terrorjack__ has quit [Ping timeout: 250 seconds]
adi________ has quit [Ping timeout: 250 seconds]
adrianbrink has quit [Ping timeout: 250 seconds]
sspi__ has quit [Ping timeout: 250 seconds]
bytesighs has quit [Ping timeout: 250 seconds]
jeroud has quit [Ping timeout: 250 seconds]
<pino|work> Leonidas: no problem! i know basically nothing about opam (other than what it is), so i just mentioned what i saw :)
rfv has quit [Ping timeout: 250 seconds]
bitonic has quit [Ping timeout: 250 seconds]
<Leonidas> these can be specified easily and since distributions come with augeas it is easy enough once i fihure out the package names :)
kakadu has joined #ocaml
ski has quit [Ping timeout: 268 seconds]
<Netsu> ggole: but how `x` there could be constrained to have same the `key` type then?
andreypopp has joined #ocaml
nkaretnikov has joined #ocaml
alexelcu has joined #ocaml
monad_cat has joined #ocaml
ski has joined #ocaml
<ggole> Use the same type variable
robmyers has joined #ocaml
adi________ has joined #ocaml
<pino|work> Leonidas: libaugeas-dev on de-based, augeas-devel on rpm-based
adrianbrink has joined #ocaml
sspi__ has joined #ocaml
rfv has joined #ocaml
bitonic has joined #ocaml
bytesighs has joined #ocaml
<ggole> Well, the modules have the same type (as above) then their keys will have the same type anyway.
kakadu_ has quit [Ping timeout: 245 seconds]
jeroud has joined #ocaml
terrorjack__ has joined #ocaml
<ggole> What are you trying to do, exactly?
<Netsu> ggole: yeah, got it! `let f (type k) (x : (module Caml.Map.S with type key = k) as 'a) (y : k) : unit = ();;` Thank you so much!
<pino|work> Leonidas: with the exception of libaugeas-devel on mageia
<Leonidas> interesting, there is no conf-libxml2
<companion_cube> howdy
emias has joined #ocaml
<Netsu> Or even `let f (type k) : x:((module Caml.Map.S with type key = k) as 'a) -> y:'a -> z:k -> unit = fun ~x:(_) ~y:(_) ~z:(_) -> ();;` Awesome!
<pino|work> Leonidas: ah, most probably you need to install pkg-config too
<Leonidas> pino|work: yep. Looks like now we're getting somewhere :)
<Leonidas> - ocamlfind: [WARNING] You have installed DLLs but the directory /home/opam/.opam/4.02/lib/stublibs is not mentioned in ld.conf
<pino|work> Leonidas: no need to add libxml2 manually, it ought to be picked by the augeas devel
<Leonidas> pino|work: yeah, I assume this was because pkg-config was not installed, I'll remove it once I get the build on Alpine to succeed
<Leonidas> I could go and bother kit_ty_kate in person to get it merged :D
zolk3ri has quit [Quit: Lost terminal]
<pino|work> Leonidas: the opam ci is green :)
emias has quit [Quit: Reboot.]
FreeBirdLjj has joined #ocaml
<sgnb> rwmjones, pino|work: virt-top FTBFS with latest ocaml-libvirt from git (34f46b0) with "pattern-matching is not exhaustive" in screen.ml... what version of ocaml-libvirt am I supposed to take?
<pino|work> sgnb: latest, i guess
<pino|work> i mean, git/master
<sgnb> that's what I did...
<pino|work> hmm
<rwmjones> it should definitely work with master
<rwmjones> sgnb: do you have the line number in screen.ml?
freyr69 has quit [Remote host closed the connection]
<pino|work> oh that's because of a change i did in ocaml-libvirt
<sgnb> rwmjones: 45
<rwmjones> I guess the show_state function; yes the patch yesterday
<rwmjones> not actually a problem, but it needs changes to virt-top
<pino|work> that one, yes
<rwmjones> is it actually that one?
<sgnb> Here is an example of a case that is not matched: InfoPMSuspended
<rwmjones> it's this one from last year: 0cdf64914edac4922dcd9f2b6b0d4b3b06e29ffa
<rwmjones> sgnb: if you add that case (not sure what presentation char to map it to) does it work?
<rwmjones> we do really need a release of libvirt-ocaml but I still haven't got around to working out how to update the website
nullifidian_ has joined #ocaml
emias has joined #ocaml
nullifidian__ has quit [Ping timeout: 248 seconds]
sonologico has joined #ocaml
<sgnb> rwmjones: with this patch: https://salsa.debian.org/ocaml-team/virt-top/blob/debian/sid/debian/patches/Fix-FTBFS-with-recent-ocaml-libvirt.patch it works (but please tell me what character should be put there instead of that 's')
<rwmjones> so that's the character which is presented on screen to show a suspended VM
<sgnb> that's what I thought
<rwmjones> as for what it should be, I guess I have no preference, but it should be documented in the man page too, and I guess upper case to match the others
<rwmjones> I managed to get access to libvirt.org/ocaml so I'll fix up the website now and then do a release
<sgnb> rwmjones: of virt-top as well?
* sgnb hopes libguestfs is not too broken by these new versions
sonologico_ has joined #ocaml
sonologico has quit [Ping timeout: 276 seconds]
KeyJoo has joined #ocaml
kakadu_ has joined #ocaml
kakadu has quit [Ping timeout: 268 seconds]
ggole has quit [Quit: Leaving]
sonologico has joined #ocaml
sonologico_ has quit [Ping timeout: 272 seconds]
Haudegen has quit [Quit: Bin weg.]
<rwmjones> we'll still need your patch to virt-top
ravenous_ has joined #ocaml
kakadu_ has quit [Ping timeout: 276 seconds]
ravenous_ has quit [Ping timeout: 264 seconds]
sonologico has quit [Remote host closed the connection]
sonologico has joined #ocaml
<Netsu> Can I have type of some abstract dictionary (map)?
<Netsu> just analogue to `void func<K,V>(dict: Dict<K,V>, val:V, key:K);`
<Netsu> for `let get (type a) ~from:((module F) : (module Caml.Map.S)) ~to_:(m : a F.t)` that escape it's scope
<Leonidas> pino|work: rwmjones: is there some kind of bug submission place? OPAM linter complains I didn't note one but I assume this is because there is none?
<Leonidas> pino|work: fails on travis though, probably because of sandboxing somehow.
<rwmjones> Leonidas: you can email virt-tools-list@redhat.com, or else pino & me
<rwmjones> actually even better: augeas-devel@redhat.com
<Leonidas> hmm, I don't even know what the bug-reports field in OPAM means. I'll just write an email here and hope for the best
<Netsu> I can get a key `type _ from = From : (module Caml.Map.S with type key = 'a) -> 'a from;;` but can't the value.
kakadu has joined #ocaml
ziyourenxiang has quit [Ping timeout: 245 seconds]
sonologico_ has joined #ocaml
sonologico has quit [Ping timeout: 250 seconds]
sonologico_ has quit [Remote host closed the connection]
sonologico has joined #ocaml
AtumT has joined #ocaml
sonologico has quit [Remote host closed the connection]
sonologico has joined #ocaml
sonologico has quit [Remote host closed the connection]
Haudegen has joined #ocaml
Serpent7776 has joined #ocaml
bartholin has joined #ocaml
FreeBirdLjj has quit [Remote host closed the connection]
vicfred has joined #ocaml
kakadu has quit [Quit: Konversation terminated!]
mbuf has quit [Quit: Leaving]
rosterok has joined #ocaml
<Netsu> Why type from module could be inferred, but not the first-class module's type? https://gist.github.com/Pitometsu/6a346dd626f6eb62576d16b4b06e7507
<Netsu> is it even possible to write polymorphic over any dictionary function?
<Netsu> perhaps the only way here is wrap function in functor, doh
averell has quit [Ping timeout: 272 seconds]
jao has quit [Ping timeout: 246 seconds]
ravenous_ has joined #ocaml
kakadu has joined #ocaml
sagax has joined #ocaml
sonologico has joined #ocaml
averell has joined #ocaml
gareppa has joined #ocaml
bitwinery has joined #ocaml
bitwinery has quit [Remote host closed the connection]
bitwinery has joined #ocaml
picolino has quit [Ping timeout: 244 seconds]
picolino has joined #ocaml
Netsu has quit [Ping timeout: 260 seconds]
Guest56755 has quit [Ping timeout: 248 seconds]
jnavila has joined #ocaml
khodzha1 has joined #ocaml
jnavila_ has joined #ocaml
jnavila has quit [Ping timeout: 248 seconds]
ravenous_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tane has quit [Quit: Leaving]
Birdface has quit [Ping timeout: 264 seconds]
jao has joined #ocaml
gravicappa has quit [Ping timeout: 246 seconds]
khodzha1 has quit [Quit: Leaving.]
ravenous_ has joined #ocaml
Serpent7776 has quit [Quit: leaving]
ravenous_ has quit [Ping timeout: 276 seconds]
Haudegen has quit [Quit: Bin weg.]
jnavila_ has quit [Remote host closed the connection]
narimiran has quit [Ping timeout: 246 seconds]
kakadu has quit [Remote host closed the connection]
Skaterhaym has joined #ocaml
bitwinery has quit [Ping timeout: 248 seconds]
KeyJoo has quit [Quit: KeyJoo]
Hrundi_V_Bakshi has joined #ocaml
Skaterhaym has quit [Read error: Connection reset by peer]
gareppa has quit [Quit: Leaving]
Birdface has joined #ocaml
AtumT has quit [Quit: AtumT]
nullifidian_ has quit [Read error: Connection reset by peer]
nullifidian__ has joined #ocaml
Denommus has joined #ocaml
rosterok has quit [Quit: Connection closed for inactivity]
ravenous_ has joined #ocaml
spew has quit [Quit: Connection closed for inactivity]
ravenous_ has quit [Ping timeout: 250 seconds]
ziyourenxiang has joined #ocaml
Hrundi_V_Bakshi has quit [Ping timeout: 245 seconds]
ravenous_ has joined #ocaml
ravenous_ has quit [Ping timeout: 276 seconds]
Denommus has quit [Remote host closed the connection]