adrien changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org and http://caml.inria.fr | http://ocaml.org/releases/4.02.0.html | Public channel logs at http://irclog.whitequark.org/ocaml
lordkryss has quit [Quit: Connection closed for inactivity]
badon_ has joined #ocaml
SomeDamnBody has joined #ocaml
badon has quit [Disconnected by services]
badon_ is now known as badon
q66[lap] has quit [Ping timeout: 250 seconds]
eikke has quit [Quit: leaving]
eikke has joined #ocaml
chris2 has quit [Ping timeout: 265 seconds]
manud has joined #ocaml
Nahra has quit [*.net *.split]
martintrojer has quit [*.net *.split]
dav has quit [*.net *.split]
fraggle-boate has quit [*.net *.split]
evert has quit [*.net *.split]
pii4 has quit [*.net *.split]
ddosia has quit [*.net *.split]
stux has quit [*.net *.split]
tianon has quit [*.net *.split]
xaimus_ has quit [*.net *.split]
dmbaturin has quit [*.net *.split]
jerith has quit [*.net *.split]
johnelse has quit [*.net *.split]
mcclurmc has quit [*.net *.split]
bytbox has quit [*.net *.split]
mbac has quit [*.net *.split]
milosn has quit [*.net *.split]
jpdeplaix has quit [*.net *.split]
pharpend has quit [*.net *.split]
teiresias has quit [*.net *.split]
majoh has quit [*.net *.split]
bjorkintosh has quit [*.net *.split]
Unhammer has quit [*.net *.split]
freling has quit [*.net *.split]
_2can has quit [*.net *.split]
companion_cube has quit [*.net *.split]
xorpse has quit [*.net *.split]
srax has quit [*.net *.split]
siddharthv_away has quit [*.net *.split]
zapu has quit [*.net *.split]
asmanur_ has quit [*.net *.split]
mcclurmc has joined #ocaml
bytbox has joined #ocaml
mbac has joined #ocaml
jpdeplaix has joined #ocaml
majoh has joined #ocaml
milosn has joined #ocaml
pharpend has joined #ocaml
xorpse has joined #ocaml
companion_cube has joined #ocaml
teiresias has joined #ocaml
freling has joined #ocaml
_2can has joined #ocaml
srax has joined #ocaml
bjorkintosh has joined #ocaml
Unhammer has joined #ocaml
siddharthv_away has joined #ocaml
zapu has joined #ocaml
asmanur_ has joined #ocaml
chris2 has joined #ocaml
Nahra has joined #ocaml
martintrojer has joined #ocaml
dav has joined #ocaml
fraggle-boate has joined #ocaml
ddosia has joined #ocaml
stux has joined #ocaml
xaimus_ has joined #ocaml
jerith has joined #ocaml
evert has joined #ocaml
pii4 has joined #ocaml
tianon has joined #ocaml
johnelse has joined #ocaml
dmbaturin has joined #ocaml
Nahra has quit [Max SendQ exceeded]
Nahra has joined #ocaml
manud has quit [Quit: manud]
thusStyles has joined #ocaml
<thusStyles> Hi, anyone know if these two types are isomorphic, I think they're not but im unsure - bool -> bool and bool * bool
srcerer has quit [Ping timeout: 272 seconds]
badon has quit [Quit: Leaving]
jwatzman|work has quit [Quit: jwatzman|work]
<thusStyles> anyone?
SomeDamnBody has quit [Ping timeout: 265 seconds]
AltGr has joined #ocaml
dsheets has quit [Ping timeout: 258 seconds]
SomeDamnBody has joined #ocaml
thusStyles has quit [Ping timeout: 246 seconds]
manud has joined #ocaml
manud has quit [Quit: manud]
hausdorff has quit [Remote host closed the connection]
waneck has quit [Quit: Leaving]
yomimono has quit [Ping timeout: 265 seconds]
pyon has quit [Quit: emacs effed up]
taion809 has joined #ocaml
pyon has joined #ocaml
dotfelix has joined #ocaml
ygrek has joined #ocaml
manud has joined #ocaml
shinnya has quit [Ping timeout: 246 seconds]
SomeDamnBody has quit [Ping timeout: 244 seconds]
badkins has quit []
dotfelix has quit [Ping timeout: 245 seconds]
dotfelix has joined #ocaml
yomimono has joined #ocaml
dotfelix has quit [Ping timeout: 245 seconds]
jbzza has joined #ocaml
<jbzza> I understand that this is probably not the right place to ask this question, but how can I allocate more stack memory to a program?
<jbzza> I tried changing the default Unix stack frame allocation, but it had not effect
ygrek_ has joined #ocaml
<jbzza> Or is the actual stack being overflowed?
ygrek has quit [Ping timeout: 245 seconds]
appd has joined #ocaml
dotfelix has joined #ocaml
marynate has joined #ocaml
trap_exit has joined #ocaml
<trap_exit> is there any way to get a type signature that promises me "this function is pure and does not do any IO" ?
manizzle has quit [Ping timeout: 245 seconds]
jbzza has quit [Quit: Page closed]
dotfelix has quit [Quit: Leaving]
samrat has joined #ocaml
<Bluddy> trap_exit: no. ocaml always allows for side effects
darkf_ has joined #ocaml
darkf has quit [Ping timeout: 265 seconds]
Submarine has quit [Ping timeout: 244 seconds]
appd has quit [Quit: Leaving...]
darkf_ is now known as darkf
Submarine has joined #ocaml
yomimono has quit [Ping timeout: 245 seconds]
<trap_exit> is there, by any chance, some superior language which would allow me to do this? :-)
<c74d> trap_exit: I suppose Haskell, Idris, and… Eff? would be superior for that purpose.
<c74d> Of those, I believe Eff is the closest to OCaml.
taion809 has quit [Remote host closed the connection]
samrat has quit [Quit: Computer has gone to sleep.]
pyon has quit [Quit: rcirc on GNU Emacs 24.4.1]
pyon has joined #ocaml
pyon has quit [Client Quit]
pyon has joined #ocaml
ygrek_ has quit [Ping timeout: 250 seconds]
trap_exit has quit [Ping timeout: 246 seconds]
Submarine has quit [Remote host closed the connection]
pharpend_ has joined #ocaml
<pharpend_> Hi guys
<pharpend_> In utop, is there an analog to ghci's :l and :r?
<pharpend_> basically, load the functions in a file into the repl
ontologiae has quit [Ping timeout: 258 seconds]
samrat has joined #ocaml
darkf_ has joined #ocaml
darkf has quit [Disconnected by services]
darkf_ is now known as darkf
manud has quit [Ping timeout: 245 seconds]
darkf_ has joined #ocaml
darkf has quit [Ping timeout: 272 seconds]
darkf_ is now known as darkf
darkf_ has joined #ocaml
<hugomg> pharpend_: might be #load "filename.ml" or #use "filename.ml"
<pharpend_> okay
hugomg has quit [Quit: Page closed]
<pharpend_> my laptop is at 9% battery, so imma exit
pharpend_ has quit [Quit: WeeChat 0.4.3]
darkf has quit [Ping timeout: 265 seconds]
darkf_ has quit [Ping timeout: 272 seconds]
pharpend has quit [Quit: WeeChat 0.4.3]
pharpend has joined #ocaml
es917 has joined #ocaml
es917 has quit [Client Quit]
darkf has joined #ocaml
claudiuc has quit [Remote host closed the connection]
pyon has quit [Quit: rcirc on GNU Emacs 24.4.1]
pyon has joined #ocaml
Submarine has joined #ocaml
Submarine has joined #ocaml
Submarine has quit [Changing host]
hausdorff has joined #ocaml
hausdorf_ has joined #ocaml
hausdorff has quit [Read error: Connection reset by peer]
hausdorff has joined #ocaml
hausdorf_ has quit [Read error: Connection reset by peer]
samrat has quit [Ping timeout: 240 seconds]
araujo has quit [Read error: Connection reset by peer]
araujo has joined #ocaml
samrat has joined #ocaml
ggole has joined #ocaml
AlexRussia has quit [Ping timeout: 265 seconds]
keen__ has joined #ocaml
keen_ has quit [Ping timeout: 246 seconds]
AlexRussia has joined #ocaml
axiles has joined #ocaml
hausdorff has quit [Remote host closed the connection]
hausdorff has joined #ocaml
hausdorff has quit [Remote host closed the connection]
hausdorff has joined #ocaml
pharpend_ has joined #ocaml
MercurialAlchemi has joined #ocaml
segmond has quit [Ping timeout: 255 seconds]
ollehar has joined #ocaml
oscar_toro has joined #ocaml
arj has joined #ocaml
ollehar has quit [Ping timeout: 246 seconds]
segmond has joined #ocaml
cago has joined #ocaml
pharpend_ has quit [Ping timeout: 244 seconds]
ebzzry_ has quit [Read error: Connection reset by peer]
ebzzry_ has joined #ocaml
c74d has quit [Remote host closed the connection]
c74d has joined #ocaml
manud has joined #ocaml
Bluddy has quit [Quit: Connection closed for inactivity]
arj has quit [Quit: Leaving.]
ygrek_ has joined #ocaml
Thooms has joined #ocaml
badon has joined #ocaml
Thooms_ has joined #ocaml
Thooms has quit [Ping timeout: 260 seconds]
zpe has joined #ocaml
<whitequark> jpdeplaix: once at the end
manud has quit [Quit: manud]
Submarine has quit [Ping timeout: 258 seconds]
ysz has joined #ocaml
badon has quit [Read error: Connection reset by peer]
badon has joined #ocaml
divyanshu has joined #ocaml
grumio2 has joined #ocaml
AlexRussia has quit [Ping timeout: 245 seconds]
Submarine has joined #ocaml
zz_adgtl is now known as adgtl
adgtl is now known as anildigital
dddd has quit [Ping timeout: 272 seconds]
ysz has quit [Remote host closed the connection]
Simn has joined #ocaml
ollehar has joined #ocaml
ebzzry_ has quit []
ebzzry has joined #ocaml
dddd has joined #ocaml
darkf_ has joined #ocaml
darkf has quit [Disconnected by services]
darkf_ is now known as darkf
grumio2 has quit [Ping timeout: 265 seconds]
kakadu has joined #ocaml
vogler has joined #ocaml
ysz has joined #ocaml
q66[lap] has joined #ocaml
dsheets has joined #ocaml
anildigital is now known as adgtl
sgnb has quit [Remote host closed the connection]
sgnb has joined #ocaml
adgtl is now known as zz_adgtl
zz_adgtl is now known as adgtl
adgtl is now known as anildigital
oscar_toro has quit [Ping timeout: 260 seconds]
jonludlam has joined #ocaml
ysz has quit [Remote host closed the connection]
ygrek_ has quit [Ping timeout: 260 seconds]
Thooms_ has quit [Quit: WeeChat 1.0.1]
arj has joined #ocaml
manud has joined #ocaml
lordkryss has joined #ocaml
eizodo has joined #ocaml
anildigital is now known as adgtl
Thooms has joined #ocaml
oscar_toro has joined #ocaml
_andre has joined #ocaml
manud has quit [Quit: manud]
dddd has quit [Ping timeout: 272 seconds]
adrien_oww has quit [Ping timeout: 240 seconds]
<jpdeplaix> whitequark: ok, good. Thanks
binnisb has joined #ocaml
marynate has quit [Ping timeout: 246 seconds]
marynate has joined #ocaml
binnisb has quit [Quit: Leaving]
binnisb has joined #ocaml
arj has quit [Quit: Leaving.]
<troydm> anyone here responsible for llvm bindings for Ocaml ?
ysz has joined #ocaml
<whitequark> me
ysz has quit [Remote host closed the connection]
<troydm> whitequark: llvm_target.mli DataLayout module add_to_pass_manager function's comment says following: "[add_to_pass_manager dl pm] adds the target data [dl] to the pass manager [pm]."
<troydm> whitequark: however the actual function signature takes passmanager as first argument and not the second as I've expected and as most pass related functions do
sepp2k has joined #ocaml
arj has joined #ocaml
<whitequark> fixed in r220377, thanks
<troydm> whitequark: I'm confused about this as I was following Kaleidoscope LLVM tutorial for OCaml and in Chapter 4 there is a line that adds data layout pass to pass manager which was not compiling so I started looking through code and found that function changed and Kaleidoscope tutorial was probably out of sync with actual code
<whitequark> yes, the tutorial is out of sync.
<troydm> whitequark: ohh, it was a bug, okey, cool, nice to know that I've contributed a slight bit to LLVM bindings for OCaml
<troydm> whitequark: thx alot
ygrek_ has joined #ocaml
hausdorff has quit [Remote host closed the connection]
arj has quit [Quit: Leaving.]
adgtl is now known as zz_adgtl
arj has joined #ocaml
jabesed has joined #ocaml
zz_adgtl is now known as adgtl
adgtl is now known as anildigital
q66[lap] has quit [Ping timeout: 250 seconds]
q66[lap] has joined #ocaml
q66[lap]_ has joined #ocaml
q66[lap] has quit [Ping timeout: 250 seconds]
anildigital is now known as adgtl
ysz has joined #ocaml
adrien_oww has joined #ocaml
adgtl is now known as zz_adgtl
Thooms has quit [Quit: WeeChat 1.0.1]
pyon has quit [Quit: "work"]
ysz has quit [Remote host closed the connection]
samrat has quit [Ping timeout: 245 seconds]
ygrek_ has quit [Ping timeout: 260 seconds]
ysz has joined #ocaml
arj has quit [Quit: Leaving.]
arj has joined #ocaml
<whitequark> oh god, fucking camomile also requires camlp4
<whitequark> I *hoped* that I could develop in peace, but noooooo
<flux> how dare they use the standard ocaml metaprogramming tool!
<whitequark> more like, how dare they use a deprecated metaprogramming tool!
<whitequark> it actually impairs my ability to do things right now, it's not just a philosophical obstacle
<Drup> It will not be deprecated as long as debian is still with something <= 4.02.0
<flux> which is still very new, doesn't really have a conversion path and has less features
<whitequark> Drup: it *is* deprecated, or at least it works like it is deprecated
<whitequark> it barely works on 4.02, no one cared to update it to use new syntax, and it doesn't work at all on 4.03
<companion_cube> what does camomile use camlp4 for?
<whitequark> I have no idea
<whitequark> I hadn't even thought that it could use camlp4 for anything before I tried to install it just now
<flux> I was going to say ppx isn't even documented, but how wrong I was: http://caml.inria.fr/pub/docs/manual-ocaml/extn.html#sec243
<whitequark> there is even a short intro into writing AST transformations
<whitequark> however it doesn't seem to be on the website
<whitequark> I think the 4.02.1 docs weren't uploaded yet
<flux> I wish there was actual official documentation alongside the other stuff
<flux> oh
<whitequark> I wrote it.
<whitequark> and it was merged.
<flux> cool!
<Leonidas> whitequark: I think when camomile was last released, ppx didn't even exist yet ;)
<flux> btw, is some findlib support coming to ppx/already exists?
<Drup> already here
<flux> along with explicit ocamlbuild support would be nice
<Drup> I don't see what support you want for ocamlbuild
<flux> <*>: ppx(ppx_foo) ?
<flux> or something.
<flux> like its findlib support
<whitequark> flux: yes, I added ppx support to findlib
<Drup> no, you do it at the findlib level
<whitequark> you just use package(whatever.ppx)
<flux> oh, nice
<flux> figured it would have needed some special handling, but that's a no then
<flux> how about ppx files you need to compiling the rest of the files?
<whitequark> hm?
<flux> you have a project that has both ppx and then files that make use of said ppx
<whitequark> myocamlbuild.ml rules
<whitequark> just like for camlp4 extensions
<flux> right, so it's the tradditional way then
<flux> well man can hope.. ;-)
<Leonidas> findlib works really quite well with ppx.
<Leonidas> even oasis works :-)
<whitequark> Drup: yay, lwt now works with --disable-camlp4
<Drup> nice :)
<whitequark> camomile only uses camlp4 for ... tools/camomilelocaledef
ysz has quit [Remote host closed the connection]
<whitequark> oh.
<whitequark> it uses camlp4 for its godawful parser syntax.
<whitequark> ... I think I can just overwrite that with the preprocessed form at opam level
<ggole> Don't forget to salt the earth after burning
<whitequark> you know, it's not even that less readable
<whitequark> Drup: can I have Default$: ocaml_version >= 4.02 in OASIS?
<whitequark> something like that
<Drup> I think I tried that once
<Drup> I didn't do it in the end, so I guess it doesn't work.
<companion_cube> I wonder whether good parser combinators would be as convenient as camlp4 stream parsers
<nicoo> whitequark: aps Camomille uses the “revised syntax” :>
* nicoo runs away
<whitequark> nicoo: huh?
<Drup> companion_cube: the camlp4 stream syntax is the only thing that make streams usable ...
<nicoo> whitequark: s/aps/perhaps/
* nicoo is having keyboard issues
<Drup> whitequark: I wonder if we should replace "base-no-ppx" by "base-ppx" instead, it would be more consistent with other base packages
<whitequark> Drup: that doesn't make sense.
<whitequark> you can't make a negative dependency in opam
<Drup> you can't ?
<Drup> hum, right nvm then
<whitequark> well, there's conflicts
<whitequark> but it will be very confusing
<whitequark> argh, I tried to search github for ocaml_version in _oasis
Bluddy has joined #ocaml
<whitequark> but the thing is, github can't restrict search to filename, and since OASIS pastes itself into setup.ml... the results are full of crap
<flux> hmm, the future? deprecation of camlp4 also means the revised syntax is finally deprecated as well?
<whitequark> it was never used anyway
<whitequark> except by camlp4 itself I guess
<Drup> except in files implementing a camlp4 syntax extension
<flux> so when will they be ported to ppx :P
<companion_cube> Drup: well, my point: streams really suck, so does camlp4, better ditch them both
<flux> they do, but is there a ppx-version of the stream parsers yet?
<flux> if not, maybe that would be a fun thing to practice ppx :)
<Drup> No, you shouldn't use Stream.
<flux> but you might have old code you wish to modernize with the smallest of an effort
<companion_cube> it should be possible to write a stream parser based on a sane notion of iterator
* companion_cube whistles
<MercurialAlchemi> you're thinking about sequences?
<Drup> companion_cube: https://github.com/alainfrisch/sedlex/pull/11 non un-releated
<companion_cube> or generators, or even JST's iterators
<Drup> MercurialAlchemi: sequence is not suited
<Drup> gen is
<MercurialAlchemi> (as somebody who hasn't used streams yet, what's the problems with them?)
<companion_cube> oh
<whitequark> Drup: nice
<Drup> MercurialAlchemi: slow, crappy interface
<Drup> insane implementation, too
<MercurialAlchemi> sounds delightful
<MercurialAlchemi> somebody should mercy-kill the stdlib
<companion_cube> :D
<companion_cube> only parts of it
<Drup> tbh, I don't understand Stream's implementation
<Drup> I would really like xavier leroy to explain the rational to me
<ggole> Yeah, even the names are a bit wtf
<companion_cube> I think the idea is for Stream to be able to put things back at the front of the stream
<ggole> There's even Obj.set_field, blurgh
<companion_cube> SCons, and all that
<Drup> ah, apparently I was wrong it's not xavier's work, someone named "Daniel de Rauglaudre" which I don't know about.
ygrek_ has joined #ocaml
<whitequark> hahaha
darkf has quit [Quit: Leaving]
BitPuffin has joined #ocaml
<Leonidas> [WARNING] External solver failed with inconsistent return value.
<Leonidas> [WARNING] Errors while parsing ppx_tools.0.99 OPAM file, skipping.
<Leonidas> hilarious
<nicoo> whitequark: Actually, I know at least one intern who worked on Camomille 2-3 months ago
jao has joined #ocaml
jao has quit [Changing host]
jao has joined #ocaml
<whitequark> nicoo: well, the maintainer explicitly said that there will be no more releases
<whitequark> this is not encouraging
<nicoo> That's sad, the intern fixed bugs in Camomille :(
<Drup> nicoo: are you sure he was not working on the other utf8 lib by the same author ?
<nicoo> Sorry, brain fart : I confused Camomille and Coccinelle ><'
<nicoo> Ignore everything I just said :þ
<Drup> camomille is not going to be developed more because the main author decided to walk away from the monolithic approach followed by camomille, and decided to develop a set of small independent libraries. see https://github.com/yoriyuki/ucorelib
<Leonidas> still dumping the responsibility of patching it on downstream maintainers kinda sucks.
<whitequark> Drup: and decided to reinvent every library that dbuenzli wrote so far
<Drup> whitequark: tbf, collaborating with dbuenzli is not easy, but yes
<whitequark> I don't think he even tried.
<Drup> I don't know.
larhat has joined #ocaml
<troydm> whitequark: quick question, where can I get latest source code for LLVM bindings for OCaml?
yomimono has joined #ocaml
<Drup> llvm dev repo http://llvm.org/git/llvm
<Drup> (or the github mirror)
jao has quit [Ping timeout: 244 seconds]
bytbox has quit [Remote host closed the connection]
zz_adgtl is now known as adgtl
adgtl is now known as anildigital
anildigital is now known as zz_anildigital
_twx_ has joined #ocaml
samrat has joined #ocaml
<whitequark> lol
<whitequark> if a CSource: required in _oasis has a syntax error, the error is silently ignored
samrat has quit [Quit: Computer has gone to sleep.]
divyanshu has quit [Quit: Connection closed for inactivity]
<troydm> Drup: ahh, ic, thx
ontologiae has joined #ocaml
binnisb has quit [Ping timeout: 244 seconds]
SethTIsue has joined #ocaml
shinnya has joined #ocaml
eizodo has quit [Quit: Page closed]
seanmcl has joined #ocaml
badkins has joined #ocaml
AltGr has left #ocaml [#ocaml]
hcarty has joined #ocaml
morphles has joined #ocaml
<hcarty> opam 1.2rc4 wants to remove lots of packages and downgrade lots of others to update Lwt from 2.4.5 to 2.4.6. opam 1.1.1 on the same installation didn't have an issue with the upgrade. Any pointers on how to track down why this is happening?
<hcarty> In the opam 1.2 case: === 1 to install | 40 to reinstall | 1 to upgrade | 19 to downgrade | 4 to remove ===
<hcarty> Not quite what I was hoping for
<Drup> hcarty: do you have aspcud ?
oscar_toro has quit [Ping timeout: 256 seconds]
<hcarty> Drup: No. This is a CentOS 6 system so it's not pre-packaged that I know of. I haven't attempted to build from source yet.
<hcarty> Build aspcud that is
rand000 has joined #ocaml
cago has left #ocaml [#ocaml]
<Drup> if you really can't build aspcud locally, you may try http://cudf-solvers.irill.org/index.html
jabesed has quit [Quit: Konversation terminated!]
jabesed has joined #ocaml
morphles has quit [Ping timeout: 255 seconds]
tane has joined #ocaml
Thooms has joined #ocaml
ollehar has quit [Ping timeout: 250 seconds]
SethTIsue has quit [Ping timeout: 244 seconds]
<Drup> whitequark: the 1.2 to 1.1 scripts are not merged in the repository
<whitequark> sigh
<hcarty> Drup: Thanks, I'll try with the external solver for now. I'm reluctant to spend my time chasing down the aspcud dependency list.
<hcarty> Drup: And that fixes it! Thank you very much.
<Drup> aspcud is a much better solver than the internal one
paddymahoney has joined #ocaml
yomimono has quit [Ping timeout: 265 seconds]
samrat has joined #ocaml
samrat has quit [Read error: Connection reset by peer]
<jpdeplaix> whitequark: ===== ERROR while installing lwt.2.4.6 =====
<jpdeplaix> # ocamlfind: Package `ppx_tools.metaquot' not found
slash^ has joined #ocaml
samrat has joined #ocaml
samrat has quit [Read error: Connection reset by peer]
<whitequark> jpdeplaix: which ocaml version are you on?
<jpdeplaix> I got this with a travis job
<jpdeplaix> Oh yes I should have linked it before
ollehar has joined #ocaml
ontologiae has quit [Ping timeout: 260 seconds]
Thooms has quit [Quit: WeeChat 1.0.1]
engil has joined #ocaml
morphles has joined #ocaml
<whitequark> the key part is: [ERROR] ppx_tools does not define the variable enable.
<whitequark> this is a problem with opam 1.1, basically
<whitequark> instead of putting --disable-ppx, it just swallows it entirely, and the option defaults to --enable... so it breaks on 4.01.
arj has quit [Quit: Leaving.]
samrat has joined #ocaml
samrat has quit [Client Quit]
Hannibal_Smith has joined #ocaml
Leonidas has quit [Ping timeout: 260 seconds]
samrat has joined #ocaml
shinnya has quit [Ping timeout: 245 seconds]
badkins has quit [Remote host closed the connection]
bytbox has joined #ocaml
lordkryss has quit [Quit: Connection closed for inactivity]
<jpdeplaix> whitequark: so how should I fix it ?
<whitequark> jpdeplaix: use opam 1.2
<whitequark> alternatively, use lwt 2.4.5
<whitequark> (I would prefer the former, it will be released to... really soon anyway)
ollehar has quit [Ping timeout: 244 seconds]
hugo has joined #ocaml
<jpdeplaix> …
<jpdeplaix> ok
hugo is now known as Guest40903
Guest40903 has left #ocaml [#ocaml]
seanmcl has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
hugomg has joined #ocaml
ygrek_ has quit [Ping timeout: 245 seconds]
tane has quit [Quit: Verlassend]
Hannibal_Smith has quit [Quit: Sto andando via]
bytbox has quit [Remote host closed the connection]
lordkryss has joined #ocaml
Muzer has quit [Excess Flood]
larhat has quit [Quit: Leaving.]
vogler has quit [Ping timeout: 256 seconds]
badkins has joined #ocaml
badkins_ has joined #ocaml
Muzer has joined #ocaml
hausdorff has joined #ocaml
badkins has quit [Ping timeout: 240 seconds]
hausdorf_ has joined #ocaml
hausdorff has quit [Read error: Connection reset by peer]
hausdorff has joined #ocaml
hausdorf_ has quit [Read error: Connection reset by peer]
hausdorf_ has joined #ocaml
hausdorff has quit [Read error: Connection reset by peer]
Hannibal_Smith has joined #ocaml
jwatzman|work has joined #ocaml
samrat has quit [Quit: Computer has gone to sleep.]
samrat has joined #ocaml
koderok has joined #ocaml
koderok has quit [Remote host closed the connection]
tac has joined #ocaml
Thooms has joined #ocaml
hausdorf_ has quit [Remote host closed the connection]
NoNNaN has joined #ocaml
hausdorff has joined #ocaml
hhugo has joined #ocaml
oscar_toro has joined #ocaml
dsheets has quit [Ping timeout: 256 seconds]
none has joined #ocaml
none is now known as Guest91783
<Guest91783> hello there
pyon has joined #ocaml
<Guest91783> I am trying hard to use the ctypes library (great work, I found it really intuitive!)
<Guest91783> still I am having some problems: do you know how to call the stat syscall using ctypes?
<jerith> I had a half-typed explanation about why ctypes is bad and you should use cffi instead, and then I noticed this is #ocaml and not #python. :-P
<Guest91783> yeah XD
<jerith> (I haven't used OCaml's ctypes, but it looks quite nice.)
<Guest91783> I am actually using this to access the stat:
<Guest91783> let stat = Foreign.foreign "stat" ~check_errno:true
<Guest91783> (string_opt @-> ptr stats @-> returning int)
<adrien> Unix has stat already
<Drup> Guest91783: "Unix.stat" ?
<Guest91783> but I get a nice Fatal error: exception Dl.DL_error("./a.out: undefined symbol: stat")
<Guest91783> Drup: I was using that before, but I need to pass a null pointer as path
<Drup> ah, that's you !
<Drup> (you changed pseudo)
<Guest91783> yeah!
<Guest91783> sorry, it seems it was used!
<jerith> I really need to get back to my OCaml code. :-/
larhat has joined #ocaml
<Guest91783> I am not an expert of IRC so I do not know yet how to fix the nick XD
<adrien> /nick foo
<adrien> /msg nickserv info none
Guest91783 is now known as none`
<none`> thanks adrien!
<adrien> have you tried generating stubs instead?
<adrien> libffi and dlopen of the libs really doesn't help with debugging
<adrien> and, hmm
<none`> adrien: I think the error means that stat is not among the stubs functions that comes with the library
<adrien> like, which library?
<none`> one of the .so file that comes with the ctypes: a sec that I try to find it again
<adrien> I don't know ctypes but this is very surprising
<adrien> what are these .so files?
kakadu has quit [Ping timeout: 246 seconds]
<none`> this is the error using the top level: "Dl.DL_error ~/.opam/4.01.0/lib/stublibs/dllctypes-foreign-base_stubs.so: undefined symbol: stat"
BitPuffin has quit [Ping timeout: 244 seconds]
<adrien> right
<adrien> I think glibc doesn't have a symbol "stat'"
<adrien> try "__stat
<adrien> try "__stat"
<adrien> or use the stubs feature
<adrien> (hint, it's going to be faster)
<none`> you're a genius!
<adrien> heh :)
<none`> it was unix_stat
<adrien> but use the stubs
<adrien> I don't think "__stat" is going to be portable
<none`> can you explain me the difference??
<adrien> simple
<adrien> from the glibc sources
<adrien> /* This definition is only used if inlining fails for this function; see the last page of <sys/stat.h>. The real work is done by the `x' function which is passed a version number argument. We arrange in the
<adrien> [...]
<adrien> the code:
<adrien> int
<adrien> attribute_hidden
<adrien> { return __xstat (_STAT_VER, file, buf);
<adrien> __stat (const char *file, struct stat *buf)
<adrien> }
<adrien> and in sys/stat.h
<adrien> __extern_inline int
<adrien> __NTH (stat (const char *__path, struct stat *__statbuf))
<adrien> { return __xstat (_STAT_VER, __path, __statbuf);
<adrien> }
<adrien> in other words the headers provide some simple tricks (although unredable) to make the operation faster
<adrien> there is no "stat" symbol ever-defined
<adrien> when you use "stat" in C code, it always ends up as something else
<none`> nooo
<none`> :o
<adrien> plus you're not handling large files
<adrien> if you use the stubs feature of ctypes, you'll instead get something and portable
<adrien> and full-featured and faster
<whitequark> why do you bind to stat at all?..
<adrien> he wants to pass NULL as first argument
<adrien> the ocaml binding won't let him
<whitequark> oh
<adrien> also, worth noting why I thought about that issue: almost the entirety of (g)libc and syscall handling is made of such niceties
<none`> okay, now I must ask again your help: I can find a description of how using stub in the ctypes tutorial, right?
<adrien> I don't know ctypes :D
<ggole> You could write a C function to return NULL and pass it to Unix.stat (with a bit of Obj.magic, cough)
<def`> (why not write a C function calling stat with NULL?)
<ggole> (This is pretty nasty as it assumes that the OCaml string is passed to the underlying system call untouched.)
<adrien> you could almost, yeah
<ggole> Yeah, that would be safer.
<adrien> but if you have an error you'll probably segfault
<adrien> actually you couldn't
<def`> And I know it's quite common to allow pointer outside the GCed heap, but that's not really good practice :P
<ggole> Is NULL even a valid value for stat(2)?
<adrien> String_val(0) won't work
<none`> ggole, def`: I was (strongly) suggested to use ctypes
<def`> none`: maybe, but what you have to write here is a 5 lines function, strong or not I would write a c stub
<adrien> actually you could :P
<adrien> def`: but I thought ctypes could generate the stubs
<adrien> "cstubs" or something like that
<whitequark> oh, it's contrived
<whitequark> you can use https://github.com/whitequark/ocaml-lz4 as an example of working with cstubs
bytbox has joined #ocaml
<def`> adrien: same problem
<adrien> hmm, I don't know how the bindings would look like
<none`> whitequark: thanks a lot!
<def`> adrien: it's quite weird to rely on the stub just because stat is not provided as a function/symbol
<none`> You all are saving time of my life: thanks!
<adrien> def`: it's a syscall, you never know how it's provided
<adrien> cf. "man vdso"
<def`> adrien: c'est bien ce que je dis
<def`> autant faire un vrai objet C à la main que d'espérer que ctypes n'y voit que du feu parce qu'il passe par des stubs
<adrien> well, my point was that by using stubs, no matter who or what makes them, the libc headers would be used and would do their work
<adrien> none`: also, you might want to look at otherlibs/unix/stat.c in the compiler sources
<adrien> unfortunately you can't simply call the stat_aux() function defined in it (you need a copy in your code)
bytbox has quit [Remote host closed the connection]
marynate has quit [Quit: Leaving]
<def`> oops, I switched to french… I said that hoping that c-types will work as a side-effect of the compilation process is really fragile. If stat is not provided as a function, then should write a proper wrapper in C
samrat has quit [Quit: Computer has gone to sleep.]
slash^ has quit [Read error: Connection reset by peer]
c74d has quit [Remote host closed the connection]
c74d has joined #ocaml
dsheets has joined #ocaml
kakadu has joined #ocaml
contempt has joined #ocaml
ollehar has joined #ocaml
<ggole> Sigh, short circuiting is a weak point of strict functional programming
<adrien> exceptions?
<ggole> They're useful, but not really very nice.
<adrien> there's a bug report on making them better for this usecase
<adrien> I don't know the current state however
<adrien> (poke def` probably)
sepp2k has quit [Quit: Konversation terminated!]
<ggole> I usually end up using a nested function as a loop
ollehar has quit [Ping timeout: 265 seconds]
<ggole> In this case I'm looking to see if a particular element is there, carrying that through to the end: if its there once, I do something with it, if its there twice, something else (that's the short circuiting part)
<ggole> So it's either two nested loops or a ref None which is set to Some x when I find the element, and then assert false in the impossible case at the end of the loop
<ggole> Ugly as hell either way.
hhugo has quit [Quit: Leaving.]
hhugo has joined #ocaml
<adrien> fold + exception to exit early?
* adrien should really write his release announcement
hausdorff has quit [Remote host closed the connection]
<ggole> Yeah, maybe
Anarchos has joined #ocaml
<def`> fold+exception yes
hausdorff has joined #ocaml
<def`> not elegant.... nothing better at the moment :o
<whitequark> adrien: release announcement?
<adrien> whitequark: win-builds 1.5
<adrien> RC1
<adrien> with zomg cute GUI on windows
<whitequark> ah
<def`> (cute == enlightenment-like theme :d?)
<adrien> def`: the previous version was GTK+2
<adrien> see
<adrien> definitely cute
<def`> adrien: I believe there is a beautiful enlightenment theme, I just never saw it
<adrien> it might not be native, it's not annoyingly non-native
<adrien> the theme isn't the issue imho, it's how much people abuse it to add animations everywhere
<def`> more native than a media player or an antivirus
<adrien> yeah
<adrien> and at least I use native windows stuff for folder browsing
<adrien> so no gtk-like braindead filebrowser
<def`> you should have kept gtk ones
<def`> :'
<adrien> the difference is that the EFL win32 port is actively worked on ;-)
<adrien> it was honestly my biggest reason
<def`> and efl being the most promising bindings in ocaml
<adrien> yeah, that helped too :)
morphles has quit [Ping timeout: 272 seconds]
claudiuc has joined #ocaml
hausdorff has quit [Remote host closed the connection]
claudiuc_ has joined #ocaml
hausdorff has joined #ocaml
AlexRussia has joined #ocaml
hhugo has quit [Quit: Leaving.]
<whitequark> o
<whitequark> I built an android cross-ocamlc with pthreads support
<whitequark> and lwt too
hhugo has joined #ocaml
<whitequark> I'm not really sure why though
<adrien> :D
<companion_cube> you must be a masochist
<adrien> fancy some windows?
<whitequark> the thought definitely crossed my mind
<whitequark> companion_cube: ^
<adrien> :D
<whitequark> adrien: I was going to test my lwt patches on mingw32, so, basically
<whitequark> yes?
<adrien> haha :)
claudiuc has quit [Ping timeout: 256 seconds]
ollehar has joined #ocaml
larhat1 has joined #ocaml
larhat has quit [Read error: Connection reset by peer]
<whitequark> hahahha, topkg returns to bite me in the ass
<adrien> :D
<whitequark> there's no way to wrangle it into installing files under my chosen prefix
<whitequark> because opam can't do that.
<whitequark> have I mentioned that I hate software, today?
<companion_cube> isn't it the case every day?
<jpdeplaix> :D
<adrien> I've been considering raising goats for several years now
<whitequark> yes. but the question was, "have I mentioned it"
<adrien> :)
<MercurialAlchemi> gnu goats?
<whitequark> heavens forbid.
<whitequark> *hunting* gnus, however...
<companion_cube> you'd rage against you spear
<companion_cube> (or bow, or whatever)
<adrien> bow or spear?
bytbox has joined #ocaml
<adrien> gattling gun!
<whitequark> a nuke
<whitequark> with clever placement, you could kill *all* gnus with just one
<Drup> considering that with clever placement, you can provoke climat change and kill almost everyone on earth .. :p
<whitequark> yes, that was the idea
<MercurialAlchemi> collateral damage
<whitequark> indirect methods are the most efficient methods
bytbox has quit [Remote host closed the connection]
<nicoo> whitequark: I don't need to do anything to kill all gnus on earth
<whitequark> huh?
<whitequark> they're LC
AlexRussia has quit [Ping timeout: 240 seconds]
<def`> LC?
<whitequark> conservation status, least concern
<def`> ok
<nicoo> whitequark: I can wait for the Sun to engulf the Earth
<whitequark> nicoo: meh, don't bother, in 200My C4 photosynthesis will become impossible anyway
<whitequark> so you only have to wait much less
manud has joined #ocaml
<nicoo> whitequark: True enough
jabesed has quit [Quit: Konversation terminated!]
<def`> … or just wait for another ice age, in 1000y, just to challenge our capacity to adapt
AlexRussia has joined #ocaml
larhat has joined #ocaml
larhat1 has quit [Ping timeout: 265 seconds]
AlexRussia has quit [Ping timeout: 240 seconds]
AlexRussia has joined #ocaml
hcarty has quit [Quit: leaving]
morphles has joined #ocaml
_andre has quit [Quit: leaving]
q66[lap]_ has quit [Changing host]
q66[lap]_ has joined #ocaml
q66[lap]_ is now known as q66[lap]
_robbins has quit [Ping timeout: 250 seconds]
lordkryss has quit [Quit: Connection closed for inactivity]
hugomg has quit [Ping timeout: 244 seconds]
hausdorff has quit [Remote host closed the connection]
_robbins has joined #ocaml
morphles has quit [Ping timeout: 246 seconds]
MercurialAlchemi has quit [Ping timeout: 272 seconds]
Mercuria1Alchemi has joined #ocaml
hugomg has joined #ocaml
ggole has quit []
badkins_ is now known as badkins
manizzle has joined #ocaml
none` has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
axiles has quit [Remote host closed the connection]
zpe has quit [Remote host closed the connection]
<whitequark> ohh great, dbuenzli suggested I use opam-installer
yomimono has joined #ocaml
badkins has quit [Ping timeout: 272 seconds]
larhat has quit [Ping timeout: 245 seconds]
zpe has joined #ocaml
<Drup> it's slightly funny that you need to invoke opam-installer manually to install something through opam.
zpe has quit [Ping timeout: 260 seconds]
hhugo has quit [Quit: Leaving.]
<smondet> Drup: hi Drup, do you have plan to opamify https://github.com/Drup/ocaml-lmdb ?
<smondet> s/have plan/plan/
<Drup> yeah, as soon as I unfucked the interface for cursor
<Drup> contributions welcome, don't have much time now
<nicoo> smondet: He has Plan9 from outer space
<smondet> Drup: where is the problem? I don't the cursor thing?
<smondet> nicoo: the movie is actually pretty fun to watch, but never tried the OS
<smondet> s/dont't the/don't see the/
<nicoo> smondet: I agree about the movie
<nicoo> And the OS is something I was bound to try at some point. I'm pretty sure no-one uses it for real anymore
<Drup> smondet: give me a sec, let me commit what I have lying around
<Drup> I have an opam file too
gargaml has joined #ocaml
<gargaml> hi
<gargaml> Is it possible to install coq through opam with 4.02.1 ocaml compiler ?
<gargaml> right now I'm getting the error "Not available for your OS or compiler"
<whitequark> no
<whitequark> I think it's because of camlp5, but not sure
<gargaml> ok, thanks
<def`> ... and coq code using comments incompatible with 4.02.1 lexing rules _0/
jbalnit has joined #ocaml
manud has quit [Quit: manud]
Anarchos has quit [Quit: Vision[0.9.7-H-20140108]: i've been blurred!]
xavierm02 has joined #ocaml
manud has joined #ocaml
xavierm02 has quit [Client Quit]
jwatzman|work has quit [Quit: jwatzman|work]
hausdorff has joined #ocaml
<Drup> smondet: ok, pushed a bunch of stuff that I forgot
<Drup> it's not ready for a release, I need to 1) add a cppo overlay to disable features based on lmdb's version
<Drup> 2) do the cursor interface
<Drup> for now, it's unsafe and not exposed
Mercuria1Alchemi has quit [Ping timeout: 272 seconds]
Leonidas has joined #ocaml
<Drup> also, I'm not completely happy with the current functor interface
<Drup> oh, and I almost forget: 3) generate stubs instead of using the dynamic stuff
Submarine has quit [Remote host closed the connection]
zpe has joined #ocaml
<Drup> I pushed an opam file, so you can pin it. Beware that you need dev ldmb version though
<Drup> pff, the mere though of having to fiddle with oasis and ocamlbuild to do the lmdb-version un-motivate me :(
Hannibal_Smith has quit [Quit: Sto andando via]
c74d has quit [Remote host closed the connection]
zpe has quit [Ping timeout: 244 seconds]
gargaml has quit [Quit: WeeChat 1.0.1]
paddymahoney has quit [Ping timeout: 240 seconds]
c74d has joined #ocaml
hugomg has quit [Ping timeout: 265 seconds]
anders0 has joined #ocaml
<smondet> Drup: cool, thanks, I'll go through it. Indeed, the cppo stuff seems annoying to handle :-/
<whitequark> Drup: huh? adding cppo support is trivial
<Drup> no, it's modifying the configure produced by oasis to get the ldmb version and pass it to cppo that I don't want to do.
<Drup> you know I'm the one who write this cppo plugin, do you ? I know how to use it with oasis :D
<whitequark> oh
<whitequark> hm
<whitequark> you could go the lwt route
<Drup> yeah, well, precisely. it unmotivates me
<whitequark> do PostConfCommand: ocaml discover.ml, and append to setup.data
<whitequark> then in myocamlbuild interrogate BaseEnvLight as usual
<Drup> yeah
<whitequark> well. don't me so lazy, what can I say
<whitequark> Lazy.force drup
ollehar has quit [Ping timeout: 246 seconds]
Simn has quit [Quit: Leaving]
<Drup> and super weird
jao has joined #ocaml
jao has quit [Changing host]
jao has joined #ocaml
kakadu has quit [Quit: Konversation terminated!]
jao has quit [Ping timeout: 246 seconds]
jwatzman|work has joined #ocaml
Thooms has quit [Quit: WeeChat 1.0.1]
yomimono has quit [Ping timeout: 245 seconds]
dsheets has quit [Ping timeout: 258 seconds]
manud has quit [Quit: manud]
hugomg has joined #ocaml
madroach has quit [Ping timeout: 250 seconds]
madroach has joined #ocaml
shinnya has joined #ocaml
malo has quit [Remote host closed the connection]
natrium1970 has joined #ocaml
<natrium1970> I’m trying to play with some things in the Num library in the toplevel. I open Num, but when I try to do anything, I get “Reference to undefined global `Num`.
NoNNaN has quit [Remote host closed the connection]
<whitequark> #require "num";;
<natrium1970> Is that needed only in the toplevel or in compiled programs, too?
NoNNaN has joined #ocaml
<whitequark> in compiled programs you'd use ocamlfind ocamlc -package num
<whitequark> or package(num) in _tags if you're using ocamlbuild
<natrium1970> Oh, okay.
<natrium1970> Thanks.
<natrium1970> #require “num”;; does not work.
<natrium1970> Error: Unbound value require
<whitequark> # is a part of the command in this case
<whitequark> not an indication of prompt
<natrium1970> Yeah, I try with and without.
<natrium1970> In fact, none of the directives work!
<whitequark> huh?
<natrium1970> Even things like #list;; fail with “Unknown directory `list’
<natrium1970> directive, thatis.
<whitequark> did you invoke #use "topfind";;
<whitequark> ?
<natrium1970> No.
<whitequark> you should put it into ~/.ocamlfind
<whitequark> and really, if you want the toplevel to be usable, install utop
<natrium1970> I havebn’t had to deal with loading things like that before.
claudiuc_ has quit [Remote host closed the connection]
<Drup> you didn't used external libraries, then
<natrium1970> No, we weren’t. We were just using the basics.
claudiuc has joined #ocaml
<rand000> Will reading of stdin always lead to the next printed string beginning on a new line? .. seems that way from the tests I've made
SomeDamnBody has joined #ocaml
robink has quit [Ping timeout: 258 seconds]
<rand000> .. fx 'print_string "foo"; flush stdout; IO.read stdin |> ignore; print_string "bar" ' will print 'foo' and 'bar' on separate lines