flux changed the topic of #ocaml to: Discussions about the OCaml programming language | http://caml.inria.fr/ | OCaml 4.00.1 http://bit.ly/UHeZyT | http://www.ocaml.org | Public logs at http://tunes.org/~nef/logs/ocaml/
<whitequark> ok... replacing ucslib
<whitequark> my fork with upstream
<pippijn> suggestions are welcome
<whitequark> CorePervasives, uhh
<whitequark> I'd like to not have that dep
<whitequark> oh wait, it's an old checkout
<whitequark> is unicode.ml outdated? or still used?
<pippijn> hmm
<pippijn> whitequark: remove it, change it into let (|>) x f = f x
<pippijn> whitequark: also, unicode.ml is not used
<pippijn> I just kept it around for reference
<whitequark> then it isn't used anywhere else
<pippijn> right
<whitequark> I'm not quite sure how to port my overlay over to this new structure
<pippijn> there are no conversions, yet
<pippijn> that is problematic
<pippijn> you can convert with fold and buffer
<pippijn> let buf = UTF_8.Buffer.create length in ignore (fold_left (fun () cp -> UTF_8.Buffer.add_char buf cp) () orig);
<pippijn> something like this
<pippijn> I suppose that would be reasonably efficient, too
<whitequark> hm? all my source strings are utf-8
<pippijn> yes, but at some point you will have UTF-32 or UTF-16
<pippijn> and then you want to convert back
Neros has quit [Ping timeout: 264 seconds]
eikke has quit [Ping timeout: 240 seconds]
* whitequark nods
<pippijn> or maybe not
<pippijn> maybe you just want to adopt and then iterate over code points
<pippijn> then you can keep it in utf-8
<pippijn> fold_left over utf-8 strings gives you code points, too
<pippijn> the interfaces are all the same, just the underlying format can vary
<pippijn> you can do (str :> string) to get it out
<pippijn> to get at the bytes
ollehar has quit [Read error: Operation timed out]
ben_zen has joined #ocaml
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
pygmalion has joined #ocaml
csakatoku has joined #ocaml
csakatoku has quit [Remote host closed the connection]
f[x] has joined #ocaml
pygmalion has quit [Ping timeout: 248 seconds]
walter has quit [Quit: This computer has gone to sleep]
osa1 has quit [Ping timeout: 245 seconds]
tobiasBora has quit [Quit: Konversation terminated!]
madroach has quit [Ping timeout: 248 seconds]
Neros has joined #ocaml
madroach has joined #ocaml
f[x] has quit [Ping timeout: 240 seconds]
travisbrady has joined #ocaml
csakatoku has joined #ocaml
q66 has quit [Quit: Leaving]
f[x] has joined #ocaml
Drup has quit [Ping timeout: 256 seconds]
mattrepl has joined #ocaml
walter has joined #ocaml
<whitequark> pippijn: I have no idea how to package libmerr as a library in merr
<pippijn> whitequark: what do you mean by package?
walter has quit [Quit: This computer has gone to sleep]
<whitequark> make it appear as Libmerr
<whitequark> Libmerr.Levenshtein etc
<whitequark> are .mllib files flat?
<pippijn> I don't know how to do that
<whitequark> that is, does libmerr.mllib imply that there's a Libmerr. in front of packaged modules?
<pippijn> in oasis, you can make a pack
<pippijn> maybe it's .mlpack
<pippijn> just guessing
<whitequark> ah, so I need both
pygmalion has joined #ocaml
<pippijn> I think it should be Merr.Levenshtein
<pippijn> I still don't know how to make packs with ocamlbuild, though
<whitequark> mlpack
<pippijn> that works?
<pippijn> then I think you just need that, and no mllib
pygmalion has quit [Ping timeout: 240 seconds]
<whitequark> no, it doesn't
<whitequark> or I'm too dumb to set it up
<pippijn> I don't know, it was just a guess
travisbrady has quit [Quit: travisbrady]
travisbrady has joined #ocaml
structuralist has joined #ocaml
Neros has quit [Ping timeout: 264 seconds]
<whitequark> siiiigh
<whitequark> js_of_ocaml can't bigint
<whitequark> anyone knows of a pure-ocaml bigint library?
<pippijn> whitequark: time to write one ;)
<whitequark> pippijn: there's only one of me :/
introom has joined #ocaml
<pippijn> yeah
<pippijn> sadly also only one of me
<pippijn> https://github.com/pippijn/aldor <- my work of tonight
<whitequark> wow
<whitequark> huge
<pippijn> all the work I did for aldor is not in that repo
<pippijn> it's in a private repo
<pippijn> I'll gradually replay those changes on this one
<whitequark> hm, so tryocaml has bigint
<pippijn> and is it actually big?
<whitequark> yes
<pippijn> indeed it is
osnr has quit [Ping timeout: 240 seconds]
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
<pippijn> that's odd
<pippijn> it appears to be byte code
<pippijn> not javascript
<whitequark> that's embedded cmis
<whitequark> toplevel wants them for... reasons
osnr has quit [Client Quit]
<pippijn> ah
<whitequark> js code itself is included as well, at the end
<pippijn> right
<pippijn> I just saw it
<whitequark> ugh. more vendored stuff, excellent
pygmalion has joined #ocaml
<pippijn> well, I don't know how they get big int then
<pippijn> I'm going home
<pippijn> dizzy.. too tired
<whitequark> hm? there's a pure-ml implementation in their tree
<pippijn> ok
<pippijn> good
darkf_ has joined #ocaml
<whitequark> oh, I need to vendor sexplib as well
pygmalion has quit [Ping timeout: 264 seconds]
darkf_ is now known as darkf
<whitequark> external div_digit_nat: nat -> int -> nat -> int -> nat -> int -> int -> nat -> int -> unit = "div_digit_nat" "div_digit_nat_native"
<whitequark> ...
<pippijn> lovely
<pippijn> what's a nat?
<pippijn> type nat = O | S of nat?
<whitequark> no
<whitequark> it's a natural number
<whitequark> bigint is composed out of a nat and a sign
<pippijn> represented as int?
<whitequark> no
mattrepl has quit [Quit: mattrepl]
<whitequark> it's represented as some kind of C bigint library
<pippijn> ah
<whitequark> I've skimmed over it, to look if it's possible to reimplement this in js_of_ocam
<whitequark> it's easier to just give up on sexplib.
<pippijn> strange
<pippijn> because I used sexplib with js
<whitequark> yes, the problem isn't sexplib itself
<whitequark> but the fact that I cannot simultaneously link system bigint (which is linked with sexplib) and my bigint
<whitequark> and system bigint is stubbed out in js_of_ocaml
<pippijn> ah
<pippijn> and you need bigint?
<whitequark> yes
<pippijn> ok
<pippijn> can't you rename your bigint?
<whitequark> hm
<whitequark> ...
<whitequark> yes.
<whitequark> wow, it compiles and works
<whitequark> sometimes I'm amazed that it does
<whitequark> thanks a lot
<pippijn> me?
<whitequark> yeah
<whitequark> it kind of did not occur to me that I can simply rename it
<whitequark> I would probably waste a lot of time.
pygmalion has joined #ocaml
breakds has quit [Quit: Konversation terminated!]
ben_zen has quit [Quit: woooooo]
ttamttam1 has joined #ocaml
ttamttam1 has left #ocaml []
sgnb` has joined #ocaml
sgnb has quit [Remote host closed the connection]
travisbrady has quit [Quit: travisbrady]
introom has quit [Remote host closed the connection]
ben_zen has joined #ocaml
pygmalion has quit [Ping timeout: 246 seconds]
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
osnr has quit [Client Quit]
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
pygmalion has joined #ocaml
osnr1 has joined #ocaml
osnr has quit [Read error: Connection reset by peer]
pygmalion has quit [Ping timeout: 246 seconds]
introom has joined #ocaml
ben_zen_ has joined #ocaml
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
osnr1 has quit [Read error: Connection reset by peer]
ben_zen has quit [Disconnected by services]
ben_zen_ is now known as ben_zen
mattrepl has joined #ocaml
mattrepl has quit [Client Quit]
osnr has quit [Quit: Leaving.]
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
ttamttam1 has joined #ocaml
BiDOrD has quit [Read error: Operation timed out]
BiDOrD has joined #ocaml
madroach has quit [Ping timeout: 248 seconds]
madroach has joined #ocaml
csakatok_ has joined #ocaml
csakatoku has quit [Ping timeout: 248 seconds]
osnr has quit [Quit: Leaving.]
f[x] has quit [Ping timeout: 260 seconds]
ben_zen has quit [Quit: leaving]
lusory_ has quit [Ping timeout: 260 seconds]
ggole has joined #ocaml
Yoric has joined #ocaml
f[x] has joined #ocaml
Simn has joined #ocaml
mika1 has joined #ocaml
cago has joined #ocaml
cago has quit [Remote host closed the connection]
cago has joined #ocaml
gnuvince has quit [Ping timeout: 240 seconds]
fds_ has quit [Ping timeout: 240 seconds]
Yoric has quit [Ping timeout: 248 seconds]
fds has joined #ocaml
nmpgaspar has joined #ocaml
beckerb has joined #ocaml
ontologiae_ has joined #ocaml
<companion_cube> oï
yacks has quit [Ping timeout: 246 seconds]
yacks has joined #ocaml
talzeus has quit [Remote host closed the connection]
eikke has joined #ocaml
smds has joined #ocaml
smds has left #ocaml []
thomasga has joined #ocaml
thomasga has quit [Client Quit]
j0sh has quit [Ping timeout: 248 seconds]
j0sh has joined #ocaml
mcclurmc has joined #ocaml
mehdid_ is now known as mehdid
introom has quit [Ping timeout: 240 seconds]
alang has quit [Ping timeout: 256 seconds]
mfp has quit [Quit: Leaving]
chambart has joined #ocaml
Yoric has joined #ocaml
Yoric has quit [Client Quit]
Yoric has joined #ocaml
Yoric has quit [Client Quit]
structuralist has quit []
Yoric has joined #ocaml
pygmalion has joined #ocaml
zpe has joined #ocaml
csakatoku has joined #ocaml
skchrko has quit [Quit: Leaving]
csakatok_ has quit [Ping timeout: 240 seconds]
mfp has joined #ocaml
pygmalion has quit [Ping timeout: 256 seconds]
csakatok_ has joined #ocaml
eikke has quit [Ping timeout: 248 seconds]
csakatoku has quit [Ping timeout: 246 seconds]
yezariaely has joined #ocaml
<yezariaely> ocaml tells me Error: This expression has type termt = t/8748 but an expression was expected of type t/8763. Can I somehow get the line number where the latter type is defined?
<mcclurmc> yezariaely: is that in the toplevel?
<yezariaely> nope, compiler output.
eikke has joined #ocaml
<flux> maybe the number is the nth character of the file?
<flux> although I don't remember seeing those for a long time.. is a preprocessor involved?
<ggole> When you get a type name with a number like that, it indicates that one of the type names are shadowed
<flux> ah yes, like: type t = A let foo = A module Z = struct type t = A let bar = foo = A end;;
gnuvince has joined #ocaml
<ggole> yezariaely: are you making use of include?
<flux> (and it appears the numbers are pretty much meaningless)
<ggole> Yeah, I think they are just internal numbers
<ggole> (This was added because people were confused by error messages where the type names were the same but the types were different.)
<yezariaely> ggole: No, the reason was the following structure. Maybe there is a better approach: http://pastebin.com/Q38i8Ejg
csakatok_ has quit [Ping timeout: 276 seconds]
<yezariaely> Maybe using Q.q instead of Q.t would be better?!
csakatoku has joined #ocaml
<vbmithr_> Hi
<vbmithr_> When doing a caml_failwith from a C binding, do I need to use CAMLparam/CAMLreturn macros or is it not necessary ?
f[x] has quit [Ping timeout: 260 seconds]
<ggole> yezariaely: hmm, ocaml should print qualified type names for code like that
<yezariaely> hmm I have to leave for 2hours
<ggole> Unless you are opening the modules or something
<yezariaely> see you later. Maye I can construct a minimal example?
<ggole> OK
<ggole> vbmithr_: if in doubt, use them
csakatok_ has joined #ocaml
q66 has joined #ocaml
csakatoku has quit [Ping timeout: 260 seconds]
csakatoku has joined #ocaml
csakatoku has quit [Remote host closed the connection]
csakatoku has joined #ocaml
skchrko has joined #ocaml
csakatok_ has quit [Ping timeout: 248 seconds]
csakatok_ has joined #ocaml
darinmorrison has joined #ocaml
csakatoku has quit [Read error: Connection reset by peer]
Sim_n has joined #ocaml
ontologiae has joined #ocaml
darinmorrison has left #ocaml []
avsm has left #ocaml []
pygmalion has joined #ocaml
csakatoku has joined #ocaml
caligula_ has joined #ocaml
csakatok_ has quit [Ping timeout: 246 seconds]
caligula__ has quit [Ping timeout: 245 seconds]
yacks has quit [Ping timeout: 276 seconds]
ontologiae_ has quit [Ping timeout: 276 seconds]
Simn has quit [Ping timeout: 276 seconds]
pygmalion has quit [Ping timeout: 240 seconds]
yacks has joined #ocaml
csakatoku has quit [Remote host closed the connection]
_andre has joined #ocaml
introom has joined #ocaml
<introom> what does the 'of' mean? # type number = Int of int | Float of float | Error;;
dsheets has quit [Ping timeout: 260 seconds]
<mrvn> introom: the type of data associated with the constructor.
<mrvn> introom: let x = Int 1 let y = Float 1.0 let z = Error
<introom> mrvn: i am inside utop, how could I clean the previous session?
<mrvn> no idea
<introom> e.g., I did let x = 3;; Now I want to del the variable x like I have never execute let x = 3;;
csakatoku has joined #ocaml
<mrvn> you can't. just ignore it or restart
dsheets has joined #ocaml
<orbitz> why does it matter what xis anyways
<introom> what does that mean: type 'a btree = Empty | Node of 'a * 'a btree * 'a btree;; is 'a an ordinary variable or the prepended ' gives it special meaning? And Node seems like not defined, also, what's the meaning of * ?
<orbitz> 'a is a type variable
<orbitz> * is tuple syntax
<orbitz> all ofthis si covered in any introductoary ocaml tutorial
<introom> orbitz: yeah, I am reading the ocaml manual, it might cover it in the later chaper.
<mrvn> introom: It's basically a placeholder for a type. When you use it it becomes an "int btree" or "float btree" or whetever btree you care to create.
skchrko has quit [Ping timeout: 256 seconds]
<orbitz> introom: a tutorial will probably introduce things in a more suitable order
<introom> sure.
pygmalion has joined #ocaml
<introom> in python repl, the previous result is stored in _, can I do it similarly in ocaml utop, like let x = _;; ? (or to say, what's the corresponding _)
<mrvn> use a toplevel with history
ollehar has joined #ocaml
pygmalion has quit [Ping timeout: 240 seconds]
skchrko has joined #ocaml
<introom> mrvn: does toplevel refer to things like utop?
<mrvn> yes
<orbitz> mrvn: he doesn't want history, he wants a special result for the last value
mcclurmc has quit [Ping timeout: 240 seconds]
<mrvn> That history. Not much of it but it is.
<mrvn> +is
<ski> (hm .. SML/NJ has `it' .. but apparently not O'Camls interactor)
kaustuv has joined #ocaml
Drup has joined #ocaml
Drup has quit [Client Quit]
Drup has joined #ocaml
Neros has joined #ocaml
<kaustuv> in ocp-build is there a way to run an arbitrary command to generate a .ml file -- like the "ocp2ml" option but user-defined ?
introom has quit [Remote host closed the connection]
<eikke> kaustuv: afaik not, I filed an issue related to it in the tracker
pygmalion has joined #ocaml
darkf has quit [Quit: Leaving]
<kaustuv> ok, thanks.
<kaustuv> part
<kaustuv> err
kaustuv has left #ocaml []
pygmalion has quit [Ping timeout: 264 seconds]
oriba has joined #ocaml
travisbrady has joined #ocaml
<eikke> did anyone ever write a bounded leaky queue (think ring-buffer) for async?
<yezariaely> ggole: just tried to minimize the error with the type numbers but I can't reconstruct it :/
<rks`> eikke: ?
<ggole> yezariaely: well, don't worry about it too much. Just remember that types with numbers on the end mean shadowing.
<eikke> rks`: there doesnt seem to be something like that in the async standard library, but maybe there's one available somewhere...
<yezariaely> ok, thx
<oriba> I'm looking for the name of a theorem (?) theory (?), that states the following: the information of an algorithm / piece of code is aequivalent to the results it can produce. I read about it a while ago, and don't know who stated this. I think I have had read this in the FP field; is that a different notion of referentoial transparency (because the code can be substituded by it's result and vice versa)???
<rks`> eikke: but, leaky?
<eikke> rks`: like a ring-buffer, if it's full, 'old' items are dropped to free up space
<rks`> oh ok
<eikke> oriba: hoare triples come to mind
<rks`> eikke: I don't know of any then.
<nmpgaspar> oriba, i see a problem with that 'theorem': side-effects
<nmpgaspar> :x
csakatoku has quit [Remote host closed the connection]
<Drup> oriba: I may be wrong but it sounds a bit like parametricity
<oriba> nmpgaspar, hmhh, the problem I have in mind is: say you have an algorithm that prints some results of a formula. The result is 10k big. But the program that generates the result is some lines of code. So, when there is some amount of information in the resulting data-table, the algorithm must be able to produce it, but needs less text, but is as powerful, regarding amount of information. Side effects or not don't matter. Do you see, what I'm look
<oriba> ing for?
<Drup> oriba: that's only the fact that your algorithm is deterministic, What sort of result do you want ?
<oriba> I'm looking for a name of this aequivalence. Is there a theorem name or so?
<oriba> and... what is an non-deterministoic algorithm?!
<companion_cube> oriba: sounds like Kolmogorov complexity
<oriba> ...hmhh, maybe it was Heinz von Foerster who wrote about this.... need to look up his papers again.,..
<oriba> companion_cube, yes, I think that's it! Many thanks! :-)
<companion_cube> :)
walter has joined #ocaml
yezariaely has quit [Ping timeout: 240 seconds]
mcclurmc_laptop has joined #ocaml
pygmalion has joined #ocaml
f[x] has joined #ocaml
<ski> oriba : mayhaps you are thinking about <http://en.wikipedia.org/wiki/Kolmogorov_complexity> ?
pygmalion has quit [Ping timeout: 240 seconds]
<oriba> ski, yes, thx; companion_cube already mentioned it.
travisbrady has quit [Quit: travisbrady]
beckerb has quit [Quit: Konversation terminated!]
<ski> oh, didn't notice
ollehar has quit [Ping timeout: 256 seconds]
mcclurmc_laptop is now known as mcclurmc
f[x] has quit [Ping timeout: 256 seconds]
<companion_cube> ski: ok, I will remember, you ignore what I say :p
ollehar has joined #ocaml
walter has quit [Read error: Connection reset by peer]
walter has joined #ocaml
Neros_ has joined #ocaml
Neros_ has quit [Remote host closed the connection]
oriba has quit [Quit: oriba]
csakatoku has joined #ocaml
csakatoku has quit [Ping timeout: 256 seconds]
<hcarty> gasche: I am not going to be able to spend any time on the Ord-related feature requests I made for Batteries over the next week or few.
malo has joined #ocaml
smondet has joined #ocaml
gereedy has joined #ocaml
zpe has quit [Remote host closed the connection]
justdit has joined #ocaml
Yoric has quit [Ping timeout: 246 seconds]
thomasga has joined #ocaml
breakds has joined #ocaml
zpe has joined #ocaml
mcclurmc has quit [Ping timeout: 240 seconds]
ollehar has quit [Ping timeout: 246 seconds]
zpe has quit [Ping timeout: 240 seconds]
jeremie has quit [Quit: WeeChat 0.4.0]
yacks has quit [Ping timeout: 246 seconds]
mika1 has quit [Quit: Leaving.]
ttamttam1 has quit [Ping timeout: 260 seconds]
cago has left #ocaml []
osa1 has joined #ocaml
ttamttam has joined #ocaml
ollehar has joined #ocaml
osa1_ has joined #ocaml
zpe has joined #ocaml
osa1 has quit [Ping timeout: 260 seconds]
yacks has joined #ocaml
Drup has quit [Ping timeout: 240 seconds]
mrvn has left #ocaml []
chambart has quit [Ping timeout: 240 seconds]
mcclurmc has joined #ocaml
osa1_ has quit [Ping timeout: 246 seconds]
metasyntax has joined #ocaml
Drup has joined #ocaml
zpe has quit [Remote host closed the connection]
<pippijn> whitequark: ok, Libmerr is better than Merr for the support library
<pippijn> whitequark: menhir does that, too
<whitequark> ok
<pippijn> and I just ran into cyclic dependencies because of it
<pippijn> Merr is also a module in the merr program
simn__ has joined #ocaml
skchrko has quit [Quit: Leaving]
sgnb`` has joined #ocaml
Neros_ has joined #ocaml
ontologiae has quit [Ping timeout: 260 seconds]
jlouis_ has joined #ocaml
aggelos__ has joined #ocaml
tizoc` has joined #ocaml
ivan\_ has joined #ocaml
noplamodo_ has joined #ocaml
metasyntax has quit [*.net *.split]
Neros has quit [*.net *.split]
Sim_n has quit [*.net *.split]
sgnb` has quit [*.net *.split]
brendan has quit [*.net *.split]
gereedy has quit [*.net *.split]
noplamodo has quit [*.net *.split]
ivan\ has quit [*.net *.split]
tizoc has quit [*.net *.split]
aggelos_ has quit [*.net *.split]
jlouis has quit [*.net *.split]
ivan\_ is now known as ivan\
nmpgaspar has quit []
brendan has joined #ocaml
metasyntax has joined #ocaml
zpe has joined #ocaml
gereedy has joined #ocaml
ollehar1 has joined #ocaml
fds_ has joined #ocaml
BiDOrD_ has joined #ocaml
malo_ has joined #ocaml
ollehar has quit [Ping timeout: 246 seconds]
fds has quit [Ping timeout: 246 seconds]
q66 has quit [Ping timeout: 246 seconds]
malo has quit [Ping timeout: 246 seconds]
BiDOrD has quit [Ping timeout: 246 seconds]
q66 has joined #ocaml
tizoc` is now known as tizoc
tizoc has quit [Changing host]
tizoc has joined #ocaml
<whitequark> I wish I could `open struct ... end'
<whitequark> oh, I can just pull the modules I need into scope
ollehar1 has quit [Ping timeout: 264 seconds]
ollehar has joined #ocaml
Yoric has joined #ocaml
ia0 has quit [Ping timeout: 248 seconds]
ia0 has joined #ocaml
yacks has quit [Ping timeout: 240 seconds]
yacks has joined #ocaml
zpe has quit [Remote host closed the connection]
mattrepl has joined #ocaml
cross_ is now known as cross
dsheets has quit [Ping timeout: 246 seconds]
tane has joined #ocaml
yacks has quit [Ping timeout: 260 seconds]
mcclurmc has quit [Ping timeout: 276 seconds]
Arsenik has joined #ocaml
Drup has quit [Ping timeout: 256 seconds]
justdit has quit [Ping timeout: 260 seconds]
tchell has quit [Ping timeout: 245 seconds]
yezariaely has joined #ocaml
tchell has joined #ocaml
_andre has quit [Quit: leaving]
Asmadeus has quit [Changing host]
Asmadeus has joined #ocaml
yacks has joined #ocaml
ggole has quit []
ollehar has quit [Ping timeout: 240 seconds]
weie has quit [Read error: Connection reset by peer]
weie has joined #ocaml
Drup has joined #ocaml
zpe has joined #ocaml
zpe has quit [Ping timeout: 260 seconds]
Anarchos has joined #ocaml
mcclurmc has joined #ocaml
ollehar has joined #ocaml
* jbrown is trying to understand something in the "Algorithm W" section of http://en.wikipedia.org/wiki/Hindley-Milner -- specifically what precisely is the meaning of "Likely, (gallows-symbol-overbar(T)) has to copy the type introducing new variables for the quantification to avoid unwanted captures."
tane has quit [Quit: Verlassend]
<jbrown> I think that in the implementation here (sorry, not ocaml ;-)) http://smallshire.org.uk/sufficientlysmall/2010/04/11/a-hindley-milner-type-inference-implementation-in-python/ that getType is implementing "inst"
<jbrown> but there doesn't seem to be anything corresponding to the part quoted above.
<jbrown> so, I don't understand where the unwanted captures alluded to can come from.
<jbrown> here's my ocaml implementation if anyone's interested -- http://pastebin.com/JdVKmx3H -- with the bit I'm questioning being "generalise". (It's full of debugging code and isn't finished, so apologies for the junk :-)).
<jbrown> fwiw it seems to work fine with or without the call to generalise... at least for the things I've tested it on. But I'm wondering if I'm missing something.
ccasin has quit [Read error: Operation timed out]
<jbrown> (this isn't homework, btw!)
ccasin has joined #ocaml
zpe has joined #ocaml
<jbrown> aha, I found http://okmij.org/ftp/ML/generalization.html. That might answer my questions!
ttamttam has quit [Remote host closed the connection]
ttamttam has joined #ocaml
mrvn has joined #ocaml
pippijn has quit [Quit: Segmentation fault]
<jbrown> (& it looks like I *was* missing something, now I just have to figure out what!)
<yezariaely> maybe the generalization to ensure polymorphism is a problem? If I recall correctly, Pierce presented an example in Types and Programming Languages.
<yezariaely> but I am not sure,
pippijn has joined #ocaml
<jbrown> I've been looking at my copy of TAPL, but it's heavy going for me :-). It's probably explained thoroughly in there somewhere...
darkf has joined #ocaml
<jbrown> my code breaks for "fun x -> let y = x in y" as given on the okmij.org page, so it looks like my generalise (...or something else) is wrong.
<jbrown> I'm not surprised, I was kind of making it up :-)
<yezariaely> Pierce provides a working example of polymorph type inference on his tapl homepage.
<yezariaely> Maybe have a look here. But I suppose he uses a substitution based variant of Algorithm W and not the side effect based variant you are looking at.
travisbrady has joined #ocaml
<jbrown> cool thanks, I'll take a look
<yezariaely> jbrown: otherwise this might help, too http://proglang.informatik.uni-freiburg.de/teaching/konzepte/2012ss/files/simple-types.pdf from page 62 on. However, this is based on unification.
<jbrown> strange, I don't see any hint of generalize in Pierce's "fullrecon"
tianon has quit [Ping timeout: 240 seconds]
walter has quit [Quit: This computer has gone to sleep]
tianon has joined #ocaml
<jbrown> ...but it does get that example right! Interesting.
<yezariaely> hehe
<yezariaely> hidden code :D
<jbrown> apparently so! :-)
osa1 has joined #ocaml
ttamttam has quit [Quit: ttamttam]
yezariaely has quit [Quit: Leaving.]
simn__ is now known as Simn
jlouis_ is now known as jlouis
walter has joined #ocaml
walter has quit [Client Quit]
* ski . o O ( "Polymorphic Type Inference" by Michael I. Schwartzbach in 1995-03 at <http://cs.au.dk/~mis/typeinf.pdf> )
Anarchos has quit [Quit: Vision[0.9.7-H-130604]: i've been blurred!]
zpe has quit [Remote host closed the connection]
Yoric has quit [Ping timeout: 246 seconds]
cdidd has quit [Read error: Connection reset by peer]
ollehar has quit [Ping timeout: 256 seconds]
cdidd has joined #ocaml
ollehar has joined #ocaml
<ollehar> if you want to play palace/"shithead" (cardgame) you can try it at tonesoftales.com
<ollehar> it's my current project, backend in ocaml, scripting in lua (for card game rules).
<ollehar> you have to have someone to play against, there's no quickmatch system yet :P
Simn has quit [Quit: Leaving]
alang_ has quit [Ping timeout: 264 seconds]
Yoric has joined #ocaml
alang_ has joined #ocaml
yacks has quit [Read error: Operation timed out]
Yoric has quit [Ping timeout: 264 seconds]
dsheets has joined #ocaml
yacks has joined #ocaml
thomasga has quit [Quit: Leaving.]
MarcWeber has quit [Ping timeout: 264 seconds]
MarcWeber has joined #ocaml
Arsenik has quit [Remote host closed the connection]
zpe has joined #ocaml
zpe has quit [Ping timeout: 245 seconds]
malo_ has quit [Quit: Leaving]
ulfdoz has joined #ocaml
Arthur_ has quit [Ping timeout: 252 seconds]
tane has joined #ocaml
cokesme has left #ocaml []
ulfdoz has quit [Ping timeout: 240 seconds]
ollehar has quit [Ping timeout: 246 seconds]
dsheets has quit [Ping timeout: 240 seconds]
travisbrady has quit [Quit: travisbrady]
tane has quit [Quit: Verlassend]
ontologiae has joined #ocaml