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/
lusory has joined #ocaml
tane has quit [Quit: Verlassend]
osnr has quit [Quit: Leaving.]
eikke has quit [Ping timeout: 256 seconds]
eikke has joined #ocaml
oriba has joined #ocaml
eikke has quit [Ping timeout: 252 seconds]
dsheets has quit [Ping timeout: 268 seconds]
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
osnr has quit [Ping timeout: 260 seconds]
madroach has quit [Ping timeout: 248 seconds]
madroach has joined #ocaml
dinosaure has quit [Read error: Connection reset by peer]
q66 has quit [Remote host closed the connection]
<amiller_> could someone who understands typedtree explain how i'd find the available types and their constructors
<amiller_> i was thinking the type_declaration might contain the list of available constructors
<amiller_> type_declaration contains a list type_cstrs, which is what i think that would be, but i don't understand its stype
<amiller_> its type*, it's type is a list of (core_type * core_type) and i don't understand that at all
ivan\ has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
ivan\ has joined #ocaml
leroux has joined #ocaml
jcao219 has joined #ocaml
oriba has quit [Quit: oriba]
emmanuelux has joined #ocaml
Zeev has quit [Disconnected by services]
Zeev has joined #ocaml
so has quit [Ping timeout: 252 seconds]
Yoric has quit [Ping timeout: 245 seconds]
so has joined #ocaml
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
Drup has quit [Quit: Leaving.]
darkf has joined #ocaml
jcao219 has quit [Ping timeout: 260 seconds]
gautamc has quit [Read error: Connection reset by peer]
gautamc has joined #ocaml
watermind has quit [Quit: Konversation terminated!]
ggole has joined #ocaml
<gasche> amiller_: "cstrs" stands for "constraints" and is not what you're looking for
<gasche> you should look at type_kind
yacks has quit [Quit: Leaving]
mattrepl has quit [Quit: mattrepl]
madroach has quit [Ping timeout: 248 seconds]
weie_ has quit [Read error: Connection reset by peer]
weie has joined #ocaml
Fnar has quit [Quit: Client exiting]
osnr has quit [Quit: Leaving.]
Yoric has joined #ocaml
ygrek has joined #ocaml
gnuvince has quit [Ping timeout: 252 seconds]
bobry_ has joined #ocaml
bobry has quit [Ping timeout: 264 seconds]
mfp has quit [Ping timeout: 264 seconds]
asmanur has quit [Ping timeout: 264 seconds]
bacam has quit [Ping timeout: 264 seconds]
bacam_ has joined #ocaml
mfp has joined #ocaml
asmanur has joined #ocaml
pr_ has quit [Ping timeout: 264 seconds]
pr has joined #ocaml
pr has quit [Changing host]
pr has joined #ocaml
bobry_ is now known as bobry
Snark has joined #ocaml
caligula__ has quit [Ping timeout: 256 seconds]
ttamttam has joined #ocaml
pootler__ has joined #ocaml
pootler_1 has joined #ocaml
ttamttam has left #ocaml []
caligula__ has joined #ocaml
Watcher7 is now known as Watcher7|off
ttamttam has joined #ocaml
ttamttam has left #ocaml []
jpdeplaix has quit [Ping timeout: 264 seconds]
Yoric has quit [Ping timeout: 245 seconds]
ollehar has joined #ocaml
<Zeev> can someone help me with opam? I try on my ubuntu 12.04 32-bit virtualbox: from this page http://opam.ocamlpro.com/doc/Quick_Install.html using apt-get, and I get: unable to locate package opam
jpdeplaix has joined #ocaml
tane has joined #ocaml
zorun has quit [Ping timeout: 256 seconds]
Yoric has joined #ocaml
<gasche> Zeev: have you added anil's repo to your sources.list as indicated on the page?
<gasche> did you do your "sudo apt-get update"?
<Zeev> yeah all the 3 lines
<Zeev> but I'm compiling from source now
<Zeev> maybe it's coz arch=amd64 and me having only 32 bits
<Zeev> not a linux pro
<Zeev> :)
<gasche> that's possible
<gasche> I don't know if avsm bothered with the 32bits packages
<gasche> so yes, compiling from source is your better option
<gasche> (but you'll need a not-too-old version of OCaml for that)
<ggole> Yes, there were no 32-bit packages when I tried to install opam (debian for me)
<ggole> I ended up building a recent ocaml and opam, both from source.
zorun has joined #ocaml
Yoric1 has joined #ocaml
Yoric has quit [Ping timeout: 260 seconds]
<gasche> hopefully the OPAM devs will not update their ocaml-version requirement too quickly
Yoric1 has quit [Ping timeout: 245 seconds]
<gasche> and in a few months most distributions will provide binary package of a recent-enough OCaml version
q66 has joined #ocaml
ulfdoz has joined #ocaml
ygrek has quit [Remote host closed the connection]
ygrek has joined #ocaml
<wmeyer> gasche: I'd hope that the user will finally have a choice of selecting opam vs. distro package
<wmeyer> I don't know if that affects me too much, as I use opam anyway, but to some extent is important
Neros has joined #ocaml
spanish has joined #ocaml
<spanish> ocaml files don't allow traditional preprocessing on input files do they? how do you guys use to pass definitions and the like from the build system? autoconf/automake in my case?
<spanish> I can pass the preprocessor to them manually and then feed it to the compiler, but much better if there's a neater way
<spanish> for example, I have added preprocessor support for mtasc, but the user might like or not to enable it at configure/build time
<ygrek> don't allow? who doesn't allow?
<ygrek> you can use external preprocessor, like cpp
<ygrek> there are preprocessor's specifically crafted for ocaml code,, like ocpp
<ygrek> there is also builtin very powerful but quite complex preprocessor camlp4
<ygrek> choose what you like
<spanish> ah, caml4p I'm using it, ocpp doesn't seem to come with a standard ocaml
<spanish> thanks I'll have a look at how I can make it all through caml4p
<wmeyer> spanish: I'd recomend any of the camlp4, which can be used for conditional compilation.
<wmeyer> s/camlp4/camlp4 packages/
<wmeyer> however most of the time it's not needed
<wmeyer> first I want to see the use case
<spanish> enabling code I wrote for mtasc?
<spanish> you might be a windows user and want a standard mtasc out of my package
<wmeyer> normally it's pleasant to use functors and conditionally choose the module on the file systen
<wmeyer> it's pitty, but didn't even try before :-)
<spanish> well, but there aren't any system modules affected here
<spanish> no, I though cmal4p was used to preprocess lexers and the like
<wmeyer> it depends what you do
<wmeyer> camlp4 is in wild can be used to implement almost any syntax and code generator
<wmeyer> where is cpp is usually limited to simple C like macros
<spanish> nice, if I can just pass definitions for macro expansion and conditional compilation I'd be more than happy with it
<spanish> yes
<wmeyer> btw: consider using cpp, just pass [-pp "gcc -M $file"] flag
<spanish> ah, thanks, I'll read up on caml4p now
<wmeyer> spanish: camlp4 takes time to master
<wmeyer> cpp macros are easy, and pleasant to use in a simple case
<spanish> yes, that might be enough for me
<wmeyer> there will be upcoming -ppx support too, which is the new pre-processor
<wmeyer> if I could see it on the release it would be great, but I think we have to wait
<spanish> ah, another one?
<wmeyer> yes, the -ppx is target for preprocessing in a new way
<spanish> nice
<wmeyer> but you highlighted an important issue, if the new user of OCaml wants to use a pre-processor, he/she needs to resort to Camlp4, which is not the best idea to begin with
<spanish> and about the lexer file, I'm using this rule
<spanish> $(OCAMLLEX) $@ $<
<wmeyer> looks good
<spanish> how would I go arround it if willing to preprocess it?
<spanish> ocamllex doesn't accept -pp option
<spanish> so I should either resort to caml4p or manually pass the preprocessor from the makefile, right?
<spanish> pass it manually I mean
<wmeyer> of course you have to run the preprocessor before the lexing, and it has to be cpp run manually, more over you have to print it to a file. Or use some other tool like ulex or sedlex, combined with -pp flag.
<wmeyer> s/before lexing/before compiling your lexer/
<spanish> if ocamllex accepts stdin input I can piped cpp's oputput right onto to it
<wmeyer> might do
<wmeyer> not the way I'd do it, but you can always use standard descriptors :-)
<wmeyer> let me know how it goes
<wmeyer> i am happy to help.
<spanish> sure, thank, I'll let you know in a minute
<spanish> echo -e '#ifdef HAVE_CONFIG_H\n #include "config.h"\n #endif\n' \
<spanish> | cat - $< | cpp -DHAVE_CONFIG_H -I.. | $(OCAMLLEX) $<
<spanish> that seems to work
ygrek has quit [Remote host closed the connection]
ygrek has joined #ocaml
tane has quit [Quit: Verlassend]
<wmeyer> yes, it looks all right, apart from that HAVE_CONFIG_H macro is from autoconf is isn't?
<spanish> yes, it's what I'm trying
<spanish> to pass definitions from the configure down to the file, for example `--enable-preprocessor'
<spanish> if that's specified, the code I wrote will get in
<spanish> there are other a bit trickier for which I might need makefile's subsitutions
<spanish> which is having an ml.in file, that configure turns into an .ml file while substituting what's necessary
<spanish> I tend not to use them if I can avoid it, but it necessary as the preprocessor doesn't get into strings
eikke has joined #ocaml
<wmeyer> ok spanish! have fun, I have to cycle to the city centre
<spanish> hehe thanks wmeyer, have a nice day
jbrown has joined #ocaml
ttamttam has joined #ocaml
eikke has quit [Ping timeout: 256 seconds]
ttamttam has left #ocaml []
ollehar1 has joined #ocaml
ollehar has quit [Ping timeout: 248 seconds]
ollehar1 has quit [Ping timeout: 248 seconds]
ollehar has joined #ocaml
Drup has joined #ocaml
lusory has quit [Ping timeout: 240 seconds]
<wmeyer> spanish: thanks, and btw, this channel is not the only (but the fastest) to talk about these topics, caml-list is also a great resource :-)
osa1 has joined #ocaml
yacks has joined #ocaml
yacks has quit [Quit: Leaving]
yacks has joined #ocaml
tane has joined #ocaml
dsheets has joined #ocaml
dsheets has quit [Quit: Leaving]
dsheets has joined #ocaml
<spanish> thanks, I'll have it present
Kakadu has joined #ocaml
rly has quit [Quit: WeeChat 0.4.2-dev]
ygrek has quit [Ping timeout: 245 seconds]
<amiller_> ah, i guess 'algebraic datatypes' in ocaml are called 'variants'
<wmeyer> amiller_: algebraic datatype is more precise and general term
eikke has joined #ocaml
<Drup> gasche: thx for the icfp list !
<gasche> you're welcome
<gasche> I was actually surprised that nobody had done that before
<Drup> gasche: the url for "Programming and Reasoning with Algebraic Effects and Dependent Types" is broken, here is the real one : http://eb.host.cs.st-andrews.ac.uk/drafts/effects.pdf
<gasche> Drup: the link I use works from my place, and it is the one Edwin gave in his blog post
<gasche> ok
<gasche> so there is a problem with how github renders the tilda in the URL
<wmeyer> gasche: it's interesting publication, thanks. When using Coq I found that dependent types preclude a bit using monads.
<wmeyer> in many cases
<gasche> Drup: so I'll go for your tilde-free URL
<gasche> wmeyer: you may be interested in the other ICFP paper about algebraic effet, by Ohad Kammar, Sam Lindley and Nicolas Oury
<wmeyer> gasche: cool, thanks
<gasche> (the webpage Drup mentioned is https://github.com/gasche/icfp2013-papers )
<wmeyer> I use PHOAS for my encodings in Coq and in many ways it looks like it replaces Reader. The other big user for evalulators the Option monad (or exception monad) already goes away with depedent types.
<amiller_> what is the ret_type_opt
<gasche> amiller_: where?
<amiller_> in the variant type decription, it's the last field, a type_expr option, associated with each variant
<gasche> I suppose it may be the return type of GADT constructors
<amiller_> ah gadts. hm
<gasche> you have to look around how it's used
<gasche> (just like everything else, in fact)
<gasche> if you want to write some comments about the various constructions as you go, as Alain did for the parsetree, that could be interesting
<asmanur> gasche: will extension_points be merged soon ?
<gasche> nothing is decided, I think
<gasche> but certainly not before 4.01
<gasche> asmanur: will mlorg be announced soon?
<asmanur> next week probably
<asmanur> i need to make a decent webpage
<gasche> (sic)
<gasche> It's funny how (sic) sounds fun in French, and mildly disgusting in English
Kakadu has quit [Ping timeout: 256 seconds]
* adrien points at asmanur and laughs
Kakadu has joined #ocaml
<adrien> html! css! javascript! loads of fun from 7 to 77!
<asmanur> yeah no
<asmanur> it's going to be written in org-mode :)
<asmanur> there's a skeleton http://kiwi.iuwt.fr/~asmanur/projects/mlorg/ but it's probably full of dead links :P
<adrien> well, at least the doc is still working =)
ulfdoz has quit [Ping timeout: 246 seconds]
Tamae has joined #ocaml
ulfdoz has joined #ocaml
Yoric has joined #ocaml
<spanish> why would it be that using ocmalopt with `-pp' causes the compiler to stop resolving things? it seems like doesn't respect `Open module' calls
<spanish> or is it any option to say "this file /tmp/algo is actually module.ml"?
<ggole> No, you have to name it the same as the module (as far as I know)
<spanish> there doesn't seem to be available some module directive to instruct/override that either
<spanish> it's being a bit of a pain to integrate ocaml
<gasche> I don't understand what you're doing regarding `-pp'
<spanish> I'd like to preprocess files, preferrably with cpp, so those files can share definitions from the build system, including doing conditional compilation
osa1 has quit [Ping timeout: 264 seconds]
<spanish> ./configure ouputs an config.h file I'd like my files to source and subsitute, mostly
Neros has quit [Ping timeout: 246 seconds]
<spanish> I can do that the dirty way, which is having a loop on the makefile which outputs "file" to "/tmp/file" once processed, such that the module system doesn't hopefuly complain
<spanish> but -cpp I can't get there, is says module x not defined, where an open module is at the top of the file
ygrek has joined #ocaml
<ggole> open just mooshes the namespace of that module into the current scope
<ggole> It doesn't define anything.
<spanish> well I have is "Error: Unbound type constructor pos" where `pos' comes from module expr
<gasche> spanish: so you cpp < file > /tmp/file, and then try to compile stuff from /tmp?
<spanish> yes, not being able to use mktemp
<gasche> this won't work
<spanish> I would do that, but preferrably wouldn't
milosn has joined #ocaml
<gasche> have you tried really using the -pp option of the OCaml compiler?
<spanish> yes, many different ways
tane has quit [Quit: Verlassend]
<gasche> could you produce a simple reproductible case of the module hierarchy and makefile you have, that would allow to test and try things directly?
<spanish> I can handle you the source if you want to
<spanish> more reproducible than that, it justs all the files on the same directory, and then this on the makefile
<gasche> ok
<gasche> it's easier for us if there are no complex compile-time dependencies (that's why I asked for a simpler reprocase; but if the sources can be compiled in isolation, that's fine)
<spanish> ok, I'll prepare it for you
<adrien> doesn't -pp work on marshalled data?
ygrek has quit [Remote host closed the connection]
ygrek has joined #ocaml
<gasche> adrien: I think you're referring to the fact that camlp4o returns a marshalled AST by default
<gasche> and OCaml accepts either source code or an AST as a result of the -pp call
<gasche> that shouldn't be a problem here, however
<adrien> ah, ok, thanks
mcclurmc has joined #ocaml
<spanish> oh, I find out the error was from ocamllex
Neros has joined #ocaml
<spanish> was getting confused with the other rule, this is my command-line:
<spanish> echo -e '#ifdef HAVE_CONFIG_H\n#include "config.h"\n#endif\n' \
<spanish> | cat - lexer.mll | cpp -E -P -w -DHAVE_CONFIG_H -I.. > /tmp/tmp.WHOHjamzKu
<spanish> Error: Unbound type constructor pos
<spanish> ok, I found out what the prpoblem was, expr.ml was empty
<spanish> I'll preprare a package that compiles
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
osnr has quit [Read error: Connection reset by peer]
osnr1 has joined #ocaml
osa1 has joined #ocaml
mattrepl has joined #ocaml
studybot_ has quit [Remote host closed the connection]
gnuvince has joined #ocaml
tane has joined #ocaml
osnr1 has quit [Quit: Leaving.]
gautamc has quit [Read error: Connection reset by peer]
<gasche> ygrek: the bugtracker has traces of you doing profiling/optimization work on ocamlbuild
<gasche> may I wonder what the conclusions were?
<gasche> (I'm looking at #5756 right now)
eikke has quit [Ping timeout: 276 seconds]
<ygrek> gasche, the main conclusion is that ocamlbuild does lots of unnecessary work and many times
<adrien> (surprise! :P )
<adrien> (but it's very good to have a proper analysis)
mattrepl has quit [Quit: mattrepl]
<gasche> I'll try to look at that in the medium-term future, but probably not for 4.01
<gasche> (well it depends)
<adrien> oh, btw: you asked me about the state of my cross-compiler stuff for the next release; as I said, I want most stuff in but I don't think I said why I didn't care for everything
<adrien> that's simply because I believe it's not doable
<gasche> you mean in a portable way?
<adrien> or even in a working way for one platform
<adrien> I don't believe everything could make it and be stable
<gasche> when you're used to git, it's painful to go back to SVN even for single commits; it's so slow
<adrien> had to do that today; promptly went back to git-svn
<adrien> s/promptly/quickly/
<gasche> promptly is fine, isn't it?
gautamc has joined #ocaml
<adrien> not sure it isn't a gallicism
<adrien> well, wordreference says it's fine =)
Yoric has quit [Ping timeout: 260 seconds]
eikke has joined #ocaml
Yoric has joined #ocaml
spanish has quit [Read error: Connection reset by peer]
darkf has quit [Quit: Leaving]
Neros has quit [Ping timeout: 248 seconds]
spanish has joined #ocaml
ollehar has quit [Ping timeout: 268 seconds]
Neros has joined #ocaml
ttamttam has joined #ocaml
ttamttam has left #ocaml []
ygrek has quit [Ping timeout: 256 seconds]
<gasche> my wild guess is that the lack of caml_applyN is a red herring
<gasche> but do you know if -lasmrun may be inactive, or what may be going wrong on Cygwin 64-bits?
Kakadu has quit [Read error: Operation timed out]
madroach has joined #ocaml
<adrien> hmmmmmmmmmmmmmmmmmmmmmm
<adrien> dunno
<adrien> but I'd start by running "nm" on the library
<adrien> well, file and nm
<gasche> feel free to say that directly in the ticket :-)
<adrien> also, GCC 4.8.1
<adrien> btw, cygwin is posix, not windows :P
* adrien nitpicks
ggole has quit []
Neros has quit [Ping timeout: 245 seconds]
Neros has joined #ocaml
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
osnr has quit [Ping timeout: 248 seconds]
ollehar has joined #ocaml
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
osnr has quit [Client Quit]
bacam_ is now known as bacam
<gasche> wmeyer: your ocamlbuild testsuite is a pleasure to extend
<wmeyer> gasche: thank you.
<wmeyer> gasche: feel free to add tests, there not many, and regression tests is what we need
<gasche> indeed
<spanish> that should be it: http://tinyurl.com/mmy5nnx
<spanish> I left on test/Makefile -pp last expression I tested
<spanish> *last -pp expression I tested
<spanish> it builds the compiler, and then compiles a dummy file I was using to test correct preprocessor support
jcao219 has joined #ocaml
<spanish> and what I'm trying to is to preprocess the files under `test/' (not needed for those under `extc/' and `swflib/', presumably) so I can send options gathered from the `configure' down to the files, as cpp declarations and be able to do conditional compilation
<gasche> I have to go now, so I won't help you tonight
<spanish> thanks, no probs
<gasche> (I'm sure other people on the chan can help as well!)
<spanish> thanks, hehe, hopefuly
ttamttam has joined #ocaml
thomasga has joined #ocaml
eikke has quit [Ping timeout: 276 seconds]
thomasga has quit [Client Quit]
<spanish> for example, after `./configure' is run, `VT100_SEQ_CLEAR' and `VT100_SEQ_RED' are defined in `config.h' so I'd like to use those on a Printf.printf from ocaml
<spanish> same as I might want to define something like COMPILE_MY_FIXES, to have my version or the original
<spanish> though variable progration can be seen other ways than just through the preprocessor
ttamttam has quit [Remote host closed the connection]
ttamttam has joined #ocaml
ttamttam has quit [Remote host closed the connection]
ttamttam has joined #ocaml
ttamttam has quit [Remote host closed the connection]
<ollehar> anyone here read/wrote "practical ocaml"?
ttamttam has joined #ocaml
ttamttam has quit [Remote host closed the connection]
ttamttam has joined #ocaml
<def-lkb_> I read what some people wrote about practical ocaml… Why ?
<ollehar> I'd like to write an ocaml tutorial
<ollehar> just wanted to know why practical ocaml got bad reviews
<ollehar> perhaps not the right place to talk about that
<adrien> gasche: I hadn't noticed something in the bug report you linked me to: the reporter is on cygwin *64*
<adrien> gasche: it's new
<adrien> fuckign timeout on mantis
<adrien> I hate losing my forms
eikke has joined #ocaml
<ollehar> perhaps if I phrase it like this: how would a good ocaml tutorial be structured?
tobiasBora has joined #ocaml
Snark has quit [Quit: leaving]
walter has quit [Quit: This computer has gone to sleep]
jcao219 has quit [Ping timeout: 246 seconds]
<ousado> ollehar: that's a broad question
<ousado> ollehar: a beginners tutorial? a tutorial for imperative/OOP refugees?
<ollehar> ousado: yeah. hm, perhaps from java to ocaml.
<ollehar> I'm using a beginners introduction to java as point of reference right now.
<ollehar> sadly, that book too got pretty poor reviews. :P
ttamttam has left #ocaml []
mattrepl has joined #ocaml
walter has joined #ocaml
jcao219 has joined #ocaml
<ousado> ollehar: there's a FP evangelist in #scala who's approach to that is "you have to forget everything"
<companion_cube> are you talking about dibblego?
<ousado> companion_cube: him and his disciples, yes
<adrien> so I can pretend that when I drink, I'm actually learning FP?
<adrien> \o/
<rks__> :D
<companion_cube> ousado: I can't stand him :)
<ousado> companion_cube: he makes it very hard for people to like him.
<companion_cube> exactly.
<ousado> except for those who are looking for some perceivedly infallible authority
<companion_cube> it's sad, because he prevents any discussion involving imperative style in scala
<companion_cube> which imho is part of why the scala community is leaning toward purely functional style
<companion_cube> (scalaz, etc.)
<ousado> mainly he prevent's #scala from being a friendly place
<ousado> *prevents
<companion_cube> yeah, also
<ousado> quasi bringing ##java to scala
<wmeyer> rks__: companion_cube ousado : hello!
<ousado> I'm not sure how much influence #scala has on the scala community as a whole, though
<ousado> wmeyer: hello :)
<wmeyer> scala is nice, the trouble is that people coming from the java background think that imperative programming is the way to go, but scala does very well ML style programming too.
<companion_cube> wmeyer: yes, but the loud part of the community pushes hard toward scalaz
* wmeyer is tired today
<companion_cube> ie, haskell-in-scala
<ousado> which scala isn't too good at
<wmeyer> ousado: is not bad eiter
<rks__> hi wmeyer
<companion_cube> implicits make it ok, but rejecting the imperative features out of fanatism is stupid
<companion_cube> those people should write haskell
<ousado> wmeyer: I don't know enough about it, but edwardk (from #haskell) mentioned there are quite deep-rooted problems with making scala behave haskell-ish, mostly JVM-related
<wmeyer> I remember, when started scala, this year, it was different experience than learning ML or Haskell
Yoric1 has joined #ocaml
<companion_cube> ousado: like, uh, the lack of tail call elimination? :D
Yoric has quit [Read error: Connection reset by peer]
<wmeyer> unfortunately, I don't have energy to do it today, for lack of motivation. At work we do scala actualy quite much
<companion_cube> ot the cost of closures
<companion_cube> (which are actually compiled to classes, I believe)
<wmeyer> but I second that it's functional language!
<wmeyer> the problem is how un-elegant syntax is ...
<ousado> I like scala, and many of the decisions that are being made
Anarchos has joined #ocaml
<wmeyer> companion_cube: yes, they are, they are lambda lifted and compiled to objects
<ousado> I've watched a talk by martin odersky not long ago, which seemed very reasonable
<companion_cube> I don't think Odersky has the same idea of how to write scala as dibblego
<companion_cube> he wouldn't have added impure features to it otherwise :/
<ousado> I mean regarding how he positioned scala in the functional languages spectrum
<ousado> exactly
<ousado> he even mentioned those folks
<ousado> more or less as an extremests group
<ousado> *extremists
<ousado> well, rather as one of the boundaries of the language
<companion_cube> heh
<companion_cube> like, using implicits to have typeclasses, and ignoring everything else :D
<ousado> dibblego thinks that using metaprogramming is unclean, for instance
<wmeyer> adrien: we shoul go for beer then!
<ousado> adrien: do you also live in cambridge?
<adrien> ousado: I wouldn't survive a week there
<wmeyer> adrien: no he doesn't but there are fast trains to and from France :-)
<ousado> heh, why?
<adrien> I need bread and dried sausage!
<ousado> haha
<wmeyer> you can try polish one :D
<adrien> good idea, next on my list :P
<adrien> going to bed now, good night =)
<wmeyer> the dried sausages, are really good in Poland. Not that I eat them at the moment, as I m half vegeterian (only fish and sea food) but you can try it.
<wmeyer> and you would be amazed how similar Polish bread is too French one
Kakadu has joined #ocaml
Kakadu has quit [Client Quit]
gnuvince has quit [Ping timeout: 252 seconds]
ygrek has joined #ocaml
Watcher7|off is now known as Watcher7
eikke has quit [Ping timeout: 252 seconds]
walter has quit [Quit: This computer has gone to sleep]
eikke has joined #ocaml
<ollehar> think like this: if you were a java programmer attempting to learn ocaml, what would you like (need) to know [about idiomatic ocaml]?
ygrek has quit [Ping timeout: 240 seconds]
<companion_cube> currying and closures, first!
<ollehar> hm
walter has joined #ocaml
fraggle_laptop has joined #ocaml
<ousado> also, object hierarchies are not a silver bullet
<companion_cube> heh
<ousado> unlike ADTs :P
<ousado> uh, I meant to say class hierarchies
<ollehar> ;)
<ousado> actually I think good examples of ADTs + pattern matching should be able to make everyone want it
<ousado> s/it/them
<ollehar> yeah
osa1 has quit [Ping timeout: 256 seconds]
<ollehar> this could be fun! "ocaml for java programmers"
<companion_cube> oh being
<companion_cube> "first, forget everything"
<ollehar> "you must unlearn, what you have learned"
<ollehar> /yoda
spanish has quit [Quit: Leaving]
<companion_cube> bullet silver, classes are not!
Yoric1 has quit [Ping timeout: 252 seconds]
<ollehar> lol
<Anarchos> i can't remember where i read that adding references to the type system make it semidecidable...
<ousado> this is very interesting in haxe, where many AS3 folks use OOP-ish progrmming styles and slowly move to more type-safe code
<ollehar> what's "haxe" and as3?
<ousado> AS3 is actionscript 3, the current language for flash-player
venk has joined #ocaml
<ousado> haxe is a programming language that translates to various other languages, like JS, AVM2 bytecode (for flash, again), C++, PHP, AS3
<ousado> haxe is a hybrid, with OOP concepts but also ADTs, structural typing, lots of nice stuff
<ousado> written in ocaml
<ousado> (the compiler)
<ousado> it has ecma-script-like syntax
<ousado> and it's the go-to language for flash programmers who fear that flashplayer is dying
<ousado> so there are many of them
<ollehar> nice, didn't know about that
<ousado> it has very strong metaprogramming facilities, which is mostly why I use it.
<ousado> (and because it makes targeting browsers/JS a non-nightmare)
eikke has quit [Ping timeout: 252 seconds]
dtg has joined #ocaml
gasche has quit [Ping timeout: 252 seconds]
Anarchos has quit [Quit: Vision[0.9.7-H-130604]: i've been blurred!]
tane has quit [Quit: Verlassend]
gasche has joined #ocaml
<ousado> I'm looking for information about the ocaml GC
<ousado> is the source code my best bet?
mattrepl has quit [Quit: mattrepl]
<ousado> thanks.
<ousado> trying to find out which assumptions the GC makes, and if/which of those might be applicable to less strict languages
eikke has joined #ocaml
<companion_cube> the main issue with the GC is mutation
<companion_cube> (imho)
jcao219 has quit [Ping timeout: 256 seconds]
<ousado> companion_cube: you mean it's optimized for immutable data?
<ousado> (the ocaml GC)
<companion_cube> yes
<companion_cube> because mutation incurs a cost (a value from the minor heap can be alive because of the major heap)
<ousado> minor -> young objects, major -> old?
<companion_cube> yes
eikke has quit [Ping timeout: 252 seconds]
osnr has joined #ocaml
osnr has quit [Changing host]
osnr has joined #ocaml
eikke has joined #ocaml
bacam has quit [Read error: Operation timed out]
bacam has joined #ocaml
<ousado> companion_cube: do you know how copying works? especially how/whether references to the moved object are updated?
ulfdoz has quit [Ping timeout: 248 seconds]
<ousado> I mean from minor to major heap
<ousado> s/copying/moving
<companion_cube> ousado: in an immutable setting, references to the minor heap are all in the minor heap
<companion_cube> so you move values to the major heap in a topological order (I think)
<companion_cube> it's more tricky if there are references from the major heap, you have to keep a list of them so that you know which references to move
oriba has joined #ocaml
<ousado> ah right.. immutable objects never have reference cycles..
eikke has quit [Ping timeout: 260 seconds]
eikke has joined #ocaml
talzeus has joined #ocaml
<ousado> amiller_: I'm just reading http://okmij.org/ftp/ML/generalization.html and thought it might be of interest to you since you mentioned typedtree (and the missong documentation) a few times
<ousado> title: "How OCaml type checker works -- or what polymorphism and garbage collection have in common"
<ousado> *missing
ollehar has quit [Ping timeout: 268 seconds]
eikke has quit [Ping timeout: 260 seconds]
q66 has quit [Remote host closed the connection]
eikke has joined #ocaml
breakds has joined #ocaml
<dsheets> ousado, let rec z = 0 :: o and o = 1 :: z
<ousado> dsheets: interesting
<ousado> dsheets: how is that represented internally?
tobiasBora has quit [Quit: Konversation terminated!]
<dsheets> ousado, let rec z = 0 :: z, too
<dsheets> cdr with pointer to cons, i believe
Zerker has joined #ocaml
ollehar has joined #ocaml
<wmeyer> dsheets: hi
<dsheets> wmeyer, hi
eikke has quit [Ping timeout: 264 seconds]
eikke has joined #ocaml