gildor changed the topic of #ocaml to: Discussions about the OCaml programming language | http://caml.inria.fr/ | OCaml 3.12.1 http://bit.ly/nNVIVH
eb4890 has joined #ocaml
ulfdoz_ has joined #ocaml
junsuijin has joined #ocaml
ulfdoz has quit [Ping timeout: 240 seconds]
ulfdoz_ is now known as ulfdoz
sebz has joined #ocaml
eb4890 has quit [Ping timeout: 255 seconds]
ikaros has quit [Quit: Ex-Chat]
ftrvxmtrx has quit [Read error: Connection reset by peer]
ftrvxmtrx has joined #ocaml
lopex has quit []
Reaganomicon has quit [Read error: No route to host]
sebz has quit [Quit: Computer has gone to sleep.]
steampunkey has quit [Quit: Page closed]
dnolen has joined #ocaml
wormphlegm has quit [Quit: leaving]
dnolen has quit [Quit: dnolen]
ulfdoz has quit [Ping timeout: 240 seconds]
sebz has joined #ocaml
iratsu has quit [Ping timeout: 264 seconds]
ankit9 has joined #ocaml
sebz has quit [Client Quit]
hcarty has quit [Remote host closed the connection]
junsuijin has quit [Quit: Leaving.]
sebz has joined #ocaml
sebz has quit [Quit: Computer has gone to sleep.]
ftrvxmtrx has quit [Read error: Connection reset by peer]
ftrvxmtrx has joined #ocaml
iratsu has joined #ocaml
larhat has joined #ocaml
edwin has joined #ocaml
<gildor> fenard: what's up ?
* gildor got 5 min
ankit9 has quit [Ping timeout: 264 seconds]
Snark has joined #ocaml
Ptival has joined #ocaml
<fenard> sry gildor just saw your message is it possible to generate libraries from oasis with path lib.sublib.subsublib ?
f[x] has joined #ocaml
ygrek has joined #ocaml
ygrek has quit [Ping timeout: 250 seconds]
Dima_ has joined #ocaml
Dima_ has quit [Client Quit]
<sgnb> strange that you didn't face the same issues
chrissbx has quit [Ping timeout: 246 seconds]
<rwmjones> looking
<Ptival> how do I pass :: to an higher-order procedure?
<rwmjones> probably something is broken in debian/unstable
<rwmjones> biab
<larhat> Ptival: you can't, because (::) is type constructor and type constructors in OCaml aren't functions. You can use (fun a b -> a :: b), though
<Ptival> larhat: hum :\ okay
<taupin> or List.cons if you use Batteries
jonathandav has joined #ocaml
ftrvxmtrx has quit [Quit: This computer has gone to sleep]
ankit9 has joined #ocaml
avsm has joined #ocaml
f[x] has quit [Quit: Leaving]
<gildor> fenard: yes, FindlibParent: sublib + FindlibName: subsublib
avsm has quit [Quit: Leaving.]
<gildor> fenard: http://darcs.ocamlcore.org/cgi-bin/darcsweb.cgi?r=odn/ocaml-data-notation;a=headblob;f=/_oasis
<gildor> fenard: in this case, you even have non-existing libraries in the path
<gildor> (FindlibContainers)
<rwmjones> hey gildor thanks for helping out Hilko
<rwmjones> there's some problem in the lablgtk2 META file, even in the Debian one ...?
<rwmjones> why doesn't -predictates init -package lablgtk2 link in the gtkInit.cmo file?
<rwmjones> I have to explicitly add -package lablgtk2.init
<gildor> rwmjones: that was almost just the -syntax camlp4o ?
<gildor> rwmjones: great
<gildor> (but thx to sgnb for the patch)
<fenard> gildor ok thanks
<rwmjones> I don't understand the -syntax arg at all ... for me, -syntax bitstring works ok on Debian and Fedora
<fenard> I'll give it a tr y
<rwmjones> so I think what I'm going to do is copy the exact META file from Debian to Fedora
<rwmjones> so that at least the behaviour is the same across both
<rwmjones> but I still think there's something wrong with it
<gildor> rwmjones: there is no init predicate in the META of lablgtk
<rwmjones> gildor: should there be?
* rwmjones is looking at wheezy here
<rwmjones> sorry, squeeze I mean
<gildor> rwmjones: hum, we don't rely on the META provided upstream in lablgtk2, maybe this is something to fix
<gildor> sgnb: ^^^
<rwmjones> I'm looking at the one in squeeze, I've not checked where it comes from
<rwmjones> in Fedora we use the META file from upstream
<rwmjones> but I'll probably change that to use the one from Debian instead
<rwmjones> it is substantially different from the one in Debian/squeeze
f[x] has joined #ocaml
Cyanure has joined #ocaml
Amorphous has quit [Ping timeout: 276 seconds]
Reaganomicon has joined #ocaml
eikke has joined #ocaml
<eikke> hija. I'm having an issue with function polymorphism, and the ocaml compiler restricting polymorphism of some function
<eikke> I defined this function: let log = Printf.kfprintf flush stderr
avsm has joined #ocaml
<eikke> if I use it once in a module, the type of the function seems to be bound to that specific usage
<eikke> as such, something like 'log "%d\n" 10; log "abc"' doesn't work (second invocation doens't type-check)
<eikke> the type of 'log' gets fixed to (int -> unit, out_channel, unit, unit) format4 -> int -> unit, which is not the intention
<eikke> any way to work around? I know about universal type quantifiers, but don't know how to apply them here
ftrvxmtrx has joined #ocaml
<eikke> using let log: 'a. ('a, out_channel, unit, unit) format4 -> 'a doesn't help
ikaros has joined #ocaml
Amorphous has joined #ocaml
<larhat> it's called "value restriction"
thomasga has joined #ocaml
arubin has quit [Quit: arubin]
thomasga has quit [Client Quit]
thomasga has joined #ocaml
<eikke> larhat: thanks! interesting stuff. eta-expansion does the trick indeed
<adrien> rwmjones, sgnb: maybe you can comment on this new META file for lablgtk: http://git.ocamlcore.org/cgi-bin/gitweb.cgi?p=lablgtk/lablgtk.git;a=blob;f=META;h=5143cb9944ac8a55b0905b99d68be2257d4ea27b;hb=refs/heads/adrien/META
<adrien> rwmjones, sgnb: I have at least two things to change: exists_if shouldn't depend on .cmxa and .cmxs files, only .cma I guess; and the next version won't link gtkInit.cmx by default
lopex has joined #ocaml
avsm has quit [Quit: Leaving.]
<rwmjones> adrien: addition of gtkInit is an improvement
<rwmjones> I don't really know enough about META files to comment intelligently on the rest
<adrien> rwmjones: thelema thinks that it's always possible that you don't want to init gtk immediately and I think I agree
<rwmjones> guess so, I can't really imagine when that would arise in any programs I wrote though
<adrien> in godi, which has gtkInit by default, if you're outside of X, ocamlnet-gtk2 will fail during configure because it's trying to init gtk, I have to check if gtkInit is the cause
<adrien> I agree it's not the usual case but ... hmmm, maybe it could be default but not force, with a "no auto init" predicate or subpackage
avsm has joined #ocaml
_andre has joined #ocaml
Znudzon has joined #ocaml
ikaros has quit [Quit: Ex-Chat]
dnolen has joined #ocaml
ztfw has joined #ocaml
munga has joined #ocaml
hcarty has joined #ocaml
hcarty has quit [Client Quit]
metasyntax|work has joined #ocaml
hcarty has joined #ocaml
<hcarty> thelema: http://vpaste.net/HtsWi? -- A patch which should allow flags to be passed to both explicitly installed packages and/or to explicity installed packages + automatically installed packages
<hcarty> thelema: A patch for odb.ml that is
eb4890 has joined #ocaml
<thelema> hcarty: thanks, I'll apply this now
<hcarty> thelema: I also have a --godi flag patch and a Arg.align patch which cleans up the --help output a bit
<hcarty> thelema: If you are interested in those as well
<thelema> can you make push requests on github?
chrissbx has joined #ocaml
<thelema> I'm having trouble `git am`-ing this patch
<thelema> $ git am configopt.patch
<thelema> Patch format detection failed.
<adrien> hcarty: what does the godi-patch do?
<hcarty> thelema: Oh - maybe due to the commit hash at the top?
<thelema> hcarty: nope, deleting that still results in failure
<hcarty> adrien: Not much - it adds a --godi flag which automatically sets "--prefix $GODI_LOCALBASE" for all packages
<hcarty> thelema: Ok. What's the process to perform a push request?
<adrien> hcarty: could be used from inside godi,
<adrien> ?
metasyntax|work has quit [Quit: WeeChat [quit]]
<adrien> meaning, if I made a new package today, I could use that?
<hcarty> adrien: It, in theory, would make using odb with GODI a bit easier. But it would not ease creating a GODI package.
<hcarty> thelema: Fork and then send a request?
<adrien> hcarty: ok, I know how to make godi packages now anyway ;-)
<thelema> yes
<thelema> fork, commit to the fork. If you can't figure out the push request, I can pull easily anyway.
<hcarty> thelema: This is my first time using github as anything other than a tool for working with someone else's project... I forked, pushed and submitted a pull request
<hcarty> thelema: Let me know if it works and/or if I need to change anything!
<thelema> the pull worked, I should still look over the other two patches...
<thelema> but they seem as trivial as the first, so...
<thelema> very good.
<hcarty> thelema: Each one is pretty trivial. If one or more of them gets cut later I won't be offended :-)
<thelema> got it.
<thelema> hcarty: is --godi needed - can't the existence of the godi environment variable trigger that behavior?
dnolen has quit [Quit: dnolen]
ftrvxmtrx_ has joined #ocaml
ftrvxmtrx has quit [Read error: Connection reset by peer]
hcarty_ has joined #ocaml
<hcarty_> thelema: The flag would allow a godi user to keep odb packages in the .odb directory
<hcarty_> I'm not sure which is the best default, but I think it would be good to support both
ftrvxmtrx_ is now known as ftrvxmtrx
<thelema> is there much of a reason to install packages outside the godi dir if there is one?
<hcarty_> Mostly for packages with binaries installed in bin I would think
<hcarty_> Testing and tweaking - it's easier to blow out and rebuild .odb than all of godi if something goes wrong
<thelema> yes, I've done this often.
metasyntax|work has joined #ocaml
Znudzon has quit [Quit: ASCII a stupid question, get a stupid ANSI!]
ikaros has joined #ocaml
sebz has joined #ocaml
AndChat- has joined #ocaml
hcarty_ has quit [Ping timeout: 255 seconds]
AndChat- has quit [Read error: Connection reset by peer]
ankit9 has quit [Quit: Leaving]
<thelema> hcarty: what's the command to install utop via odb?
<hcarty> thelema: ocaml odb.ml --configure-flags --enable-react lwt && ocaml odb.ml utop
<hcarty> thelema: I think that should do it
* NaCl needs to file some bug reports against utop
* thelema tries that
<hcarty> thelema: Oops
<hcarty> thelema: You need to install react first
<thelema> no problem, I've done that.
<hcarty> thelema: Cool. It won't be pulled in automatically as it is not listed as a dependency of Lwt
<thelema> I wonder if we should put --enable-react and a dep on react in lwt's _oasis
<hcarty> thelema: I think it's worth doing, now that React is in oasis-db
<thelema> at least lwt should install react support if react is available.
<thelema> File "src/uTop_complete.ml", line 10, characters 0-10:
<thelema> Error: Unbound module Types
<thelema> hmmm
<hcarty> thelema: What version of OCaml?
<NaCl> thelema: install the compiler libs
<thelema> hcarty: 3.12.1
<thelema> NaCl: where to? I did a make install from source...
<thelema> Install architecture-dependent files in dir: ... $prefix
<NaCl> thelema: they aren't installed by default
<thelema> hmm, this might cause odb problems sometime
<NaCl> there is a debian package for it
<thelema> NaCl: for 3.12.1?
<NaCl> oh, uh.
<NaCl> don't think so
<hcarty> thelema: I think GODI has a separate package for the compiler libraries... I'm not sure how you would do this from a raw source install
Ptival has quit [Quit: Leaving]
<hcarty> thelema: It looks like GODI installs the extra compiler libraries by copying them over manually.
<thelema> where to?
<hcarty> thelema: From typing/ and parsing/ in the source tree to wherever the compiler will find them by default
<thelema> ok, thanks
<hcarty> thelema: You're welcome. GODI copies *.cmi, *.cmi, *.o and *.cmx
<hcarty> Oh, one more - the utils/ directory is included as well
<thelema> cmi, cmo, o and cmx?
<hcarty> Yes
<NaCl> I just copied the directories over
* thelema stil has what looks like an install problem for lwt about shared object files...
<thelema> Error: Error on dynamically loaded library: dlllwt-unix.so: dlllwt-unix.so: cannot open shared object file: No such file or directory
<hcarty> thelema: Ah - depending on where lwt was installed, you may need to set CAML_LD_LIBRARY_PATH
<thelema> this is probably odb's fault, as findlib uses a different dir for shared libraries...
<hcarty> export CAML_LD_LIBRARY_PATH=/path/to/stublibs:$CAML_LD_LIBRARY_PATH
<thelema> there's also a caml ld.conf
<thelema> /usr/local/lib/ocaml/ld.conf
<hcarty> Editing that may work too
<thelema> yay, it's working
<thelema> at least it says it's installed
<thelema> batteries loads a bit slowly in it...
<hcarty> thelema: It may be utop scanning through the available modules for its completion information
<thelema> interesting... I'll try this out a bit - its tab completion is definitely better than the lwt toplevel's
<hcarty> thelema: It even provides a bit of minor syntax highlighting if you copy over one of the example rc files
<hcarty> NaCl: What bugs have you run up against?
larhat has quit [Quit: Leaving.]
blinky- has joined #ocaml
joewilliams_away is now known as joewilliams
Ptival has joined #ocaml
lopexx has joined #ocaml
eikke has quit [Ping timeout: 276 seconds]
sepp2k has joined #ocaml
rby has quit [Ping timeout: 276 seconds]
iratsu has quit [Ping timeout: 260 seconds]
drake01 has joined #ocaml
avsm has quit [Quit: Leaving.]
junsuijin has joined #ocaml
lopex has quit []
lopexx has quit []
lopex has joined #ocaml
orbitz has quit [Ping timeout: 250 seconds]
metasyntax|work has quit [Read error: Operation timed out]
sebz_ has joined #ocaml
sebz has quit [Read error: Connection reset by peer]
sebz_ is now known as sebz
munga has quit [Ping timeout: 260 seconds]
nimred has quit [Ping timeout: 250 seconds]
nimred has joined #ocaml
drake01 has quit [Ping timeout: 250 seconds]
shachaf has quit [Ping timeout: 240 seconds]
ftrvxmtrx has quit [Quit: This computer has gone to sleep]
eikke has joined #ocaml
shachaf has joined #ocaml
srcerer has joined #ocaml
ulfdoz has joined #ocaml
ikaros has quit [Quit: Ex-Chat]
ikaros has joined #ocaml
eikke has quit [Ping timeout: 246 seconds]
avsm has joined #ocaml
<thelema> given a list of ([`A|`B|`C]*'a), I want to "sort" it so that any adjacent `A and `B are not ordered `B;`A
<thelema> i.e. any runs of ABABABAABBB get sorted AAAAABBBBBB, but C's divide these runs
<thelema> (there's also a reduce function on 'a -> 'a -> 'a that can only be applied to adjacent values with the same tag (i.e. [A,x; A,y] -> [A,reduce x y])
thomasga has quit [Quit: Leaving.]
sepp2k has quit [Ping timeout: 255 seconds]
ftrvxmtrx has joined #ocaml
eikke has joined #ocaml
sepp2k has joined #ocaml
<hcarty> thelema: Split the list into AB C BA ...; sort each AB/BA list; join the resulting lists back together
<hcarty> thelema: I think BatList has a group_by or similar function to do the splitting
ftrvxmtrx has quit [Read error: Connection reset by peer]
ftrvxmtrx has joined #ocaml
ikaros has quit [Quit: Ex-Chat]
<thelema> I wonder how much more efficient my handwritten recursion will be than that
<thelema> If I had more than three tags, I'd definitely do it that way.
ftrvxmtrx has quit [Quit: Leaving]
sebz has quit [Quit: Computer has gone to sleep.]
sebz has joined #ocaml
ygrek has joined #ocaml
sebz has quit [Quit: Computer has gone to sleep.]
sebz has joined #ocaml
orbitz has joined #ocaml
sebz has quit [Client Quit]
sebz has joined #ocaml
avsm has quit [Quit: Leaving.]
ztfw has quit [Remote host closed the connection]
ftrvxmtrx has joined #ocaml
avsm has joined #ocaml
sebz has quit [Quit: Computer has gone to sleep.]
sebz has joined #ocaml
eb4890 has quit [Ping timeout: 240 seconds]
sebz has quit [Quit: Computer has gone to sleep.]
ulfdoz has quit [Ping timeout: 252 seconds]
Snark has quit [Quit: Quitte]
Cyanure has quit [Remote host closed the connection]
ygrek has quit [Ping timeout: 250 seconds]
ztfw has joined #ocaml
_andre has quit [Quit: leaving]
ftrvxmtrx has quit [Read error: Connection reset by peer]
ftrvxmtrx has joined #ocaml
edwin has quit [Remote host closed the connection]
<_habnabit> hmm, is there a better way to write `(flip f) x` ? it seems I've just done that twice in the same patch.
<malouin> (x |> f) maybe? hold on...
<malouin> nope nm
<_habnabit> oh, heh. `flip f x`
avsm has quit [Quit: Leaving.]
blinky- has quit [Quit: /quat]
ztfw has quit [Remote host closed the connection]
sebz has joined #ocaml
ikaros has joined #ocaml
iratsu has joined #ocaml
sebz has quit []
munga has joined #ocaml
ftrvxmtrx has quit [Read error: Operation timed out]
ftrvxmtrx has joined #ocaml
junsuijin has quit [Ping timeout: 250 seconds]
sebz has joined #ocaml
eikke has quit [Ping timeout: 250 seconds]
munga has quit [Quit: Ex-Chat]
junsuijin has joined #ocaml
lopex has quit [Ping timeout: 252 seconds]
dnolen has joined #ocaml
sebz has quit [Quit: Computer has gone to sleep.]
lopex has joined #ocaml
lamawithonel_ has joined #ocaml
lamawithonel has quit [Ping timeout: 250 seconds]
ftrvxmtrx has quit [Read error: Connection reset by peer]
ftrvxmtrx has joined #ocaml
junsuijin has quit [Ping timeout: 258 seconds]