ChanServ changed the topic of #ocaml to: Discussions about the OCaml programming language | http://www.ocaml.org | OCaml 4.02.1 announcement at http://ocaml.org/releases/4.02.html | Public channel logs at http://irclog.whitequark.org/ocaml
ontologiae has joined #ocaml
rand000 has quit [Quit: leaving]
rgrinberg has quit [Quit: Leaving.]
rgrinberg has joined #ocaml
NoNNaN has quit [Remote host closed the connection]
NoNNaN has joined #ocaml
oscar_toro has quit [Ping timeout: 244 seconds]
bytbox has quit [Remote host closed the connection]
ontologiae has quit [Ping timeout: 245 seconds]
shinnya has quit [Ping timeout: 240 seconds]
psy_ has quit [Read error: Connection reset by peer]
chouser has quit [Ping timeout: 252 seconds]
psy_ has joined #ocaml
ghostpl has quit [Remote host closed the connection]
ptc_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rgrinberg has quit [Quit: Leaving.]
ptc has joined #ocaml
ptc has quit [Client Quit]
MrScout has quit [Ping timeout: 245 seconds]
bytbox has joined #ocaml
bytbox has quit [Remote host closed the connection]
chouser has joined #ocaml
yminsky has joined #ocaml
jwatzman|work has quit [Quit: jwatzman|work]
yminsky has quit [Quit: yminsky]
yminsky has joined #ocaml
myyst is now known as myst
BitPuffin has joined #ocaml
enitiz has joined #ocaml
destrius has joined #ocaml
yminsky has quit [Quit: yminsky]
enitiz has quit [Ping timeout: 264 seconds]
ygrek has joined #ocaml
chouser has quit [Ping timeout: 245 seconds]
jabesed has quit [Ping timeout: 244 seconds]
bytbox has joined #ocaml
enitiz has joined #ocaml
skinkitten has quit [Quit: Leaving]
ptc has joined #ocaml
ptc is now known as Guest66889
rossberg has quit [Ping timeout: 265 seconds]
Guest66889 has quit [Client Quit]
bytbox has quit [Remote host closed the connection]
rossberg has joined #ocaml
darkf has joined #ocaml
badkins has quit []
Sorella has quit [Quit: Connection closed for inactivity]
kapil__ has joined #ocaml
chouser has joined #ocaml
swgillespie has joined #ocaml
q66 has quit [Quit: Leaving]
yminsky has joined #ocaml
rgrinberg has joined #ocaml
sdegutis has joined #ocaml
<sdegutis> Hi.
<sdegutis> Are there any good web frameworks for OCaml?
BitPuffin has quit [Ping timeout: 240 seconds]
yminsky has quit [Quit: yminsky]
<struktured> sdegutis: you mean something like eliom..or?
<sdegutis> I mean something more like Sinatra.
<sdegutis> /cc struktured
<struktured> interesting, but yeah I don't know anything offhand
<rgrinberg> sdegutis: i do, https://github.com/rgrinberg/opium
<rgrinberg> is there a way to git clone an ocaml project and only install its dependency
<rgrinberg> s/dependency/dependencies/
<rgrinberg> kind of like pin but not the package itself
AlexRussia has quit [Ping timeout: 252 seconds]
vanila has quit [Quit: Leaving]
axiles has quit [Ping timeout: 240 seconds]
AlexRussia has joined #ocaml
<struktured> rgrinberg: a hack would be opam install foo && opam remove foo
<rgrinberg> that's ugly :/
<struktured> rgrinberg: yep
<rgrinberg> I want to add generic steps on how to start hacking on some of my projects
AlexRussia has quit [Ping timeout: 246 seconds]
<struktured> rgrinberg: the only thing I was thinking you could do something opam show | grep depends | ...etc
<struktured> rgrinberg: but its still a hack basically but could be scripted with some shell foo
<rgrinberg> struktured: there's opam install --deps-only
<rgrinberg> but i'm not sure how it would work with pinning
<rgrinberg> or a local opam file at least
<struktured> rgrinberg: have you tried it yet?
<rgrinberg> struktured: which command would i use?
chouser has quit [Ping timeout: 265 seconds]
<struktured> rgrinberg: what about opam pin --no-action project-name project-folder && opam install --deps-only project-name ?
<struktured> sorry forgot the add, but u get the idea..
<rgrinberg> struktured: i think that could work
rgrinberg has quit [Quit: Leaving.]
rgrinberg has joined #ocaml
rgrinberg has quit [Client Quit]
rgrinberg has joined #ocaml
chouser has joined #ocaml
AlexRussia has joined #ocaml
jao has quit [Ping timeout: 264 seconds]
jbalint has quit [Ping timeout: 256 seconds]
jbalint has joined #ocaml
zwer_g has joined #ocaml
<struktured> rgrinberg: core and lwt? interesting combo
<rgrinberg> struktured: it was async before :P
<struktured> rgrinberg: I had a feeling there was a change, given your blog history
zwer has quit [Ping timeout: 250 seconds]
<rgrinberg> haha
<struktured> rgrinberg: opium looks cool though, maybe I'll finally not be afraid to do front end dev again
chouser has quit [Quit: Leaving.]
<rgrinberg> funny you say that, opium does nothing to help there
<struktured> well that resty api you go going on is a start
<struktured> *go/got
<rgrinberg> i'm really interested in purescript to solve my frontend woes
<struktured> there's just too many choices. It's nuts. I will probably go an ocaml solution though
<rgrinberg> js_of_ocaml is also nice but the runtime is kinda big
<rgrinberg> that doesn't always matter of course
<struktured> I can live with that
<rgrinberg> also, when I work with JS i prefer not to silo myself from the JS world. AFAIK purescript's FFI is much better (both ways)
<rgrinberg> but yeah, otherwise OCaml is natural
<struktured> I'm aiming to silo as much as possible :). I don't know js_of_ocaml too well, but I'd like to see some sort of semi-automated js library -> ocaml binding generator
<rgrinberg> there's something like ctypes https://github.com/klakplok/goji
<struktured> rgrinberg: oh yeah that looks promising. I'm hoping that this libs eliminate all the string literals that seem to pollute js
<struktured> well not all, but some at least
<struktured> the syntax seems pretty legit but the javascript injection looks a little ugly with the all the slashes and quoting etc
<rgrinberg> needs more {xxx| … |xxx} :D
lopex has quit [Quit: Connection closed for inactivity]
sdegutis has left #ocaml ["Leaving..."]
rgrinberg has quit [Quit: Leaving.]
dmiles has joined #ocaml
rgrinberg has joined #ocaml
dmiles_afk has quit [Ping timeout: 272 seconds]
<rgrinberg> struktured: add an opam file to goji as well for pinning
<rgrinberg> :D
<struktured> hmm, I thought you were going down the purescript route?
<rgrinberg> well i have a bunch of maintenance projects in JS
<rgrinberg> for those i'll try to gradually convert to purescript
nullcat has joined #ocaml
<rgrinberg> if i'm doing something from scratch then it's ocaml all the way :D
<struktured> got it, well sorry I'm not ambitious to make an opam file for goji but maybe I will if I actually star tusing it for something. I might try wrapping a js plot lib and/or tree view that way, for instance
<nullcat> whitequark hi, I don't really understand the usage of ppx_metaquot. Is it something like when you want to add a new thing in the parsetree but you don't want to write the AST manually, you can use the ppx_metaquot and write in concrete syntax. ppx_metaquot will turn it into an AST? is it like a macro in a macro?
<nullcat> and i guess a simple example is this one?:http://caml.inria.fr/cgi-bin/viewvc.cgi/ocaml/branches/extension_points/experimental/frisch/metaquot_test.ml?diff_format=l&view=markup&pathrev=13579
<nullcat> are there any other simple examples?
chouser has joined #ocaml
<struktured> geez I can literally smell my cpu burning from doing an opam upgrade
ygrek has quit [Ping timeout: 240 seconds]
<nullcat> i can finish a marathon before `opam upgrade' finishes
BitPuffin has joined #ocaml
tnguyen has joined #ocaml
BitPuffin has quit [Ping timeout: 245 seconds]
<nullcat> rgrinberg do u know how to use ppx_metaquot?
<rgrinberg> nullcat: sorry, i don't
<nullcat> ok. i'll just wait whitequark to wake up
bugabinga has quit [Ping timeout: 244 seconds]
bugabinga has joined #ocaml
<struktured> nullcat: what are you thinking of doing with it?
<struktured> nullcat: full discretion, I know little just curious
<nullcat> I have a research project that I want to use ppx and I am just trying to do it from the very beginning. I feel like ppx_metaquot can solve my problem, partially.
<nullcat> but still not sure how to use it
<nullcat> just very very simple. if i have a function "let f x = x" in the file. If I do "let f[%test] x = x", I would like the ppx to derive a new function "let p () -> print_endline "f"", just a new function that can print the name of the function...
<struktured> nullcat: you only care about the function name, not the args or anything?
<nullcat> yes
<nullcat> just starting from some simple stuff
<struktured> with args, it would rock for log based debugging
<nullcat> yeah that's the next step
<nullcat> I will appreciate if someone can guide me
<struktured> ppx_deriving_show really reminds of me all this, but its used after type definitions, typically, not let expressions
<nullcat> yes
<nullcat> whitequark's code gives me some idea
<nullcat> basically...
rgrinberg has quit [Quit: Leaving.]
rgrinberg has joined #ocaml
<nullcat> oh i guess i kind of know how to use it now...
<nullcat> it's really cool.
ygrek has joined #ocaml
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
swgillespie has joined #ocaml
<struktured> awesome
tnguyen has quit [Ping timeout: 245 seconds]
psy_ has quit [Remote host closed the connection]
tel has joined #ocaml
<nullcat> but sadly, my code failed at the very last step..."Uninterpreted extension 'getvb'." when I do `make test' https://gist.github.com/marklrh/9fda09b92d970d6d137a
<nullcat> not sure why...
ygrek has quit [Remote host closed the connection]
ygrek has joined #ocaml
Simn has joined #ocaml
chinglish has joined #ocaml
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ygrek has quit [Remote host closed the connection]
ygrek has joined #ocaml
swgillespie has joined #ocaml
ygrek has quit [Remote host closed the connection]
ygrek has joined #ocaml
chinglish has quit [Ping timeout: 245 seconds]
chinglish has joined #ocaml
larhat has joined #ocaml
ygrek has quit [Ping timeout: 246 seconds]
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
govg has quit [Ping timeout: 256 seconds]
govg has joined #ocaml
ygrek has joined #ocaml
<struktured> nullcat: where did you get that build script template from?
<nullcat> i wrote it...
tel has quit [Ping timeout: 246 seconds]
rgrinberg has quit [Quit: Leaving.]
<struktured> nullcat: are you importing anything in the test file? whenever I use ppx, I always need to import something for it to compile properly
<struktured> nullcat: never mind, I don't import to derive show explicitly..
moei has quit [Quit: Leaving...]
chouser has quit [Quit: Leaving.]
<nullcat> would u like to help me with my problem...
moei has joined #ocaml
<struktured> eh I'm going to bed soon sorry, but maybe later if you are still stuck. I imagine whitequark will solve that build issue in < 30 seconds though
larhat has quit [Quit: Leaving.]
matason has joined #ocaml
dsheets_ has joined #ocaml
waneck has quit [Ping timeout: 245 seconds]
<whitequark> who's pinging me
jonludlam has quit [Quit: Coyote finally caught me]
<nullcat> me!
<nullcat> thank god you show up finally
<nullcat> I am trying to write some ppx stuff with ppx_metaquot in the ppx_tools
<whitequark> so, the issue is that you're trying to transform let f x = [%getvb x + 1]
<nullcat> let f[%getvb] x = x + 1
<whitequark> let f[%getvb] x = x + 1 is equivalent to [%%getvb let f x = x + 1]
<whitequark> yes
<nullcat> ok i see
<whitequark> and your ppx rewriter matches what i wrote abive
<whitequark> *above
<nullcat> the first problem is that
<nullcat> make build can work
<nullcat> but ocamlfind ppx_tools/rewriter will go into infinite loop
<nullcat> i can change it into [%getvb let f x = x + 1] later. thank you. that's much better
<whitequark> you can change the match
<nullcat> the match in ppx_component.ml?
<whitequark> pstr_item = Pstr_extension({txt="getvb"}, PStr[{pstr_desc=Pstr_value...
ollehar has joined #ocaml
<nullcat> also, what i really want to here is generating a function that can print the name of the first function, really easy stuff
<nullcat> i guess you can understand what i wrote in ppx_component.ml
<whitequark> sure
<nullcat> the thing is that when i try rewriter, it will fall in infinite loop. I believe there is something going on I totally missed and it will be good if i can figure it out. after that, I can try the way you suggest
<nullcat> 'ocamlfind ppx_tools/rewriter ./ppx_component.native test_ppx_component.ml' just gives me 'let f
<nullcat> ((((((((((((((((((((((((((..........'
<whitequark> so, first, a few notes
<nullcat> yes
<whitequark> 1) use structure_item instead of structure
<whitequark> to avoid iterating the list yourself
<whitequark> a structure is just a structure item list
<whitequark> 2) a structure does not consist of expressions but structure items
<whitequark> in your case toplevel let and expression let are different
<nullcat> yes
<whitequark> you call it "expr".
<nullcat> yeah sorry i should change it to some other name
<nullcat> you mean i should write a structure_item mapper, right?
<whitequark> yes
Tekk_ has quit [Remote host closed the connection]
<dmbaturin> If I need to handle something in the middle of the list and at the end of the list in a slightly different way, is "if xs = []" in the "x :: xs" case the best way to do it, or there are better ideas?
<whitequark> nullcat: ah, the structure item suggestion won't actually work here
<whitequark> since you append an item
<dmbaturin> That is, if I don't want to duplicate most of the code in the "x :: []" case.
<nullcat> whitequark https://gist.github.com/marklrh/9fda09b92d970d6d137a i updated the gist
<whitequark> this is an annoying part in ppx
<nullcat> yep
<nullcat> that's what i want to show you in the updated jist
<nullcat> gist
<nullcat> test_ppx_component.ml is now what you suggest
<whitequark> no
<nullcat> `ast' is the AST i get.
<whitequark> that is not what i suggested
Kakadu has joined #ocaml
<nullcat> oh...
<nullcat> dmbaturin just do match ... with | ... -> ... | [x] -> ...
<nullcat> whitequark they are equivalent but yours looks better
<nullcat> so i guess [%getvb let f x = x + 1] is just fine...
mort___ has joined #ocaml
<nullcat> https://gist.github.com/marklrh/9fda09b92d970d6d137a updated the variable name
<dmbaturin> nullcat: Well, that's the question. Separate [x] may be too much duplication, while "if xs = []" doesn't feel aesthetically right.
<nullcat> dmbaturin what do you mean by 'too much duplication'?
<companion_cube> nullcat: what are you writing?
<nullcat> i am just trying to write a simple ppx extension which uses ppx_metaquot to do the following thing
<nullcat> if a function is written as "let f[%getvb] x = x + 1", i want to generate a function that can print its name, which in this case, is "f".
oscar_toro has joined #ocaml
<nullcat> but for now, things compile. but when I do ocamlfind ppx_tools/rewriter just try to verify if i get it correctly, rewriter falls into infinite loop and blows up
<companion_cube> would you give the name of f to f itself?
<companion_cube> or generate a separate function?
ghostpl has joined #ocaml
<nullcat> generate a seperate function
<nullcat> which is like, "let print_name () = print_endline "f"
<companion_cube> ok, sounds reasonable
psy_ has joined #ocaml
<nullcat> this is so far what i wrote
<companion_cube> I think you do want some metaquot :)
<nullcat> yeah i did use metaquot
<nullcat> at here
<nullcat> but the problem is that the rewriter falls into infinite loop
<dmbaturin> nullcat: E.g. if I want to search for or replace a subsequence I'll need to account for the case when the end of a subsequence is also the end of the list. Maybe I can structure if in a different way or use a nested function though.
<companion_cube> I guess you have to remove the syntax extension, but I never wrote a bare ppx
<companion_cube> only plugins to ppx_deriving
<companion_cube> dmbaturin: pattern matching is almost always the answer on list
<companion_cube> s
<nullcat> but for function i don't want to generate the function that can print its name, i want a way to distinguish them
<nullcat> whitequark: are u still here?
<whitequark> yeah, let me see
<nullcat> thank you so much
Snark has joined #ocaml
<whitequark> why do you ignore the rest of the items?
<nullcat> ah i just assume that the first function is what i want to extend now
<nullcat> i can change it later, not really important
<whitequark> btw, you botched the gist
<nullcat> oh... what
<whitequark> look at the source.
<nullcat> yes
<whitequark> anyway, your original gist can be fixed by changing
<whitequark> expr to es
<nullcat> oh i see what you mean
<nullcat> but why?
<whitequark> ... i have no idea actually
<nullcat> why are u discarding the "let f ..."
<whitequark> oh?
<whitequark> what?
<nullcat> you said i should change it to es @ pr_stru
<nullcat> instead of espr @ pr_stru
<whitequark> ... you know, this looks like a bug in Pprintast
<nullcat> ... oh god
<whitequark> yeeeep
<companion_cube> neat
<whitequark> -dparsetree succeeds with your original rewriter
<whitequark> -dsource dies
<whitequark> lol
<nullcat> can i see your -dparsetree command?
<whitequark> ocamlc -dparsetree -ppx ./ppx foo.ml
<nullcat> File "test_ppx_component.ml", line 1, characters 7-12:
<nullcat> Uninterpreted extension 'getvb'. But i saw this warning at the very end
<nullcat> ocamlc -dparsetree -ppx ./ppx_component.native test_ppx_component.ml
<whitequark> i already told you how to fix that error
<nullcat> [%%getvb let f x = x + 1]?
<whitequark> ... no
<whitequark> those two are equivalent
<nullcat> then i guess i missed what you said...
<whitequark> 08:46 < whitequark> so, the issue is that you're trying to transform let f x = [%getvb x + 1]
<whitequark> 08:46 < whitequark> let f[%getvb] x = x + 1 is equivalent to [%%getvb let f x = x + 1]
<whitequark> your ppx rewriter would transform code of form let f x = [%getvb x + 1]
<nullcat> let me see
destrius has quit [Quit: Leaving.]
larhat has joined #ocaml
<nullcat> no i changed it. still does not work...
<nullcat> and i don't understand it will only work on 'let f x = [%getvb x + 1]. I first write 'let f[%getvb] x = x + 1' and dumped its ast. I write my ppx code to manipuate the ast to get something like i dumped
<whitequark> sigh
<whitequark> right.
<whitequark> pattern (test.ml[1,0+5]..[1,0+13])
<whitequark> Ppat_extension "getvb"
<whitequark> []
<whitequark> missed this. your code is right
<nullcat> i've been working on this for a whole night. i really want to figure it out even though i have sleep at 3am
<nullcat> have to*
<whitequark> ok, i finally know what's wrong with it
<whitequark> you need to remove the extension node between feeding the AST back to compiler
<whitequark> (or the typechecker will complain)
<nullcat> remove that [%getvb] thing from the ast?
<whitequark> alternatively you could use an attribute instead of extension nodes, those get ignored by the compiler
<companion_cube> why not use [@@foo] rather than [%foo] then?
<whitequark> yeah
<nullcat> omg
<nullcat> i really wish i learnt that before...
<nullcat> omfg...
<nullcat> thank you guys!
<nullcat> so, to wrap this up. extension node should be removed from the ast. attribute note does not have to be removed b/c it can be ignore in the following step
<companion_cube> yes
<companion_cube> that's why ppx_deriving uses attribute nodes
<nullcat> ok so in what case, you want to use [%]
<whitequark> companion_cube: not really
<nullcat> and there is a [%%%]?
<companion_cube> otoh, extensions that modify code (e.g. lwt.ppx) tend to use extension nodes, because it doesn't make sense to compile without preprocessing
<whitequark> in ppx_deriving, you just don't have extension nodes in the right place
<whitequark> ie type t = {}[@@x]
<whitequark> there is no [%%%]
<whitequark> [@@@] ~ [%%]
<companion_cube> so let%lwt x = foo doesn't make sense without preprocessing
<nullcat> but this does not pass syntax check when i want to dump the ast "let f[%%getvb] x = x + 1"
<whitequark> you can't use [%% like that
<whitequark> it's a floating extension node
<whitequark> it's a structure item by itself
<nullcat> ok so now 'let f x = x + 1 [%%getvb]' works now
<nullcat> but [%%getvb] as you said is a strucuture now
<nullcat> now i have to patter matching like x :: y :: _ ->
chinglish has quit [Ping timeout: 246 seconds]
<nullcat> y is the [%%getvb] and x is the 'let f = ...'
<nullcat> right?
<whitequark> what you really need here is let%getvb f x = x + 1
<whitequark> [%%getvb] is completely independent from let
<nullcat> not let%%getvb?
<whitequark> (which was the reason for my error; your let f[%getvb] x = x + 1 looked much like let[%getvb])
<whitequark> no
<whitequark> as I've said, %% is for a structure item
<whitequark> well
<whitequark> right, this is for a structure item, after all
<whitequark> i guess this is not very straightforward, yes. still, it's let%getvb
<nullcat> ok and i don't need to remove the extension node this time?
<whitequark> you do
<whitequark> always
skinkitten has joined #ocaml
<nullcat> because u r using extension node this time
<nullcat> not attribute node
<nullcat> right?
<whitequark> yes
<nullcat> thx. going to fix it now
_andre has joined #ocaml
myst has quit [Quit: Leaving]
myyst has joined #ocaml
myyst is now known as myst
jonludlam has joined #ocaml
ontologiae has joined #ocaml
ingsoc has joined #ocaml
Haudegen has quit [Ping timeout: 245 seconds]
Haudegen has joined #ocaml
jonludlam has quit [Ping timeout: 255 seconds]
jonludlam has joined #ocaml
nullcat has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Snark has quit [Quit: leaving]
AlexRussia has quit [Ping timeout: 245 seconds]
cdidd has quit [Remote host closed the connection]
cdidd has joined #ocaml
chinglish has joined #ocaml
cdidd has quit [Remote host closed the connection]
cdidd has joined #ocaml
ygrek has quit [Ping timeout: 264 seconds]
AltGr has left #ocaml [#ocaml]
BitPuffin has joined #ocaml
ghostpl has quit [Remote host closed the connection]
Thooms has joined #ocaml
keen__________53 has joined #ocaml
keen__________52 has quit [Ping timeout: 240 seconds]
<Drup> (04:49:10) rgrinberg: js_of_ocaml is also nice but the runtime is kinda big *cough*
<Drup> No, it's not.
BitPuffin has quit [Ping timeout: 255 seconds]
skinkitten has quit [Ping timeout: 244 seconds]
<def`> Drup: it's not? or it's no longer?
<Drup> it never was and it's even smaller now
ghostpl has joined #ocaml
ollehar1 has joined #ocaml
kerneis_ has joined #ocaml
jpdeplaix1 has joined #ocaml
adrien_znc_ has joined #ocaml
Nahra` has joined #ocaml
shinnya has joined #ocaml
hsuh has joined #ocaml
asmanur_ has joined #ocaml
leowzukw has joined #ocaml
j0sh_ has joined #ocaml
skinkitten has joined #ocaml
pii_4_ has joined #ocaml
ollehar has quit [*.net *.split]
dsheets_ has quit [*.net *.split]
adrien_znc has quit [*.net *.split]
kerneis__ has quit [*.net *.split]
jpdeplaix has quit [*.net *.split]
asmanur has quit [*.net *.split]
j0sh has quit [*.net *.split]
zapu has quit [*.net *.split]
Nahra has quit [*.net *.split]
pii4 has quit [*.net *.split]
hsuh_ has quit [*.net *.split]
moviuro has quit [*.net *.split]
adrien_znc_ is now known as adrien_znc
pii_4_ is now known as pii4
ollehar1 has quit [Ping timeout: 240 seconds]
darth_lumbergh has joined #ocaml
skinkitten has quit [Ping timeout: 250 seconds]
dsheets_ has joined #ocaml
zapu has joined #ocaml
moviuro has joined #ocaml
chouser has joined #ocaml
Sorella has joined #ocaml
darth_lumbergh has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
<adrien_znc> Drup: well, it _is_ kinda big
<adrien_znc> but compared to other libraries...
chouser has quit [Quit: Leaving.]
lopex has joined #ocaml
paradoja has joined #ocaml
<Drup> It's less than 10Ko, you can't really do smaller than that
<adrien_znc> h, I thought it was closer to 70K
<Drup> hello world is 8ko
paradoja has left #ocaml ["Killed buffer"]
darth_lumbergh has joined #ocaml
<Drup> (and less than 5ko after closure)
darth_lumbergh has quit [Client Quit]
vanila has joined #ocaml
chinglish has quit [Ping timeout: 264 seconds]
enitiz has quit [Ping timeout: 255 seconds]
ghostpl has quit [Remote host closed the connection]
jabesed has joined #ocaml
chinglish has joined #ocaml
badkins has joined #ocaml
ghostpl has joined #ocaml
dario_ has joined #ocaml
AlexRussia has joined #ocaml
darth_lumbergh has joined #ocaml
darth_lumbergh has quit [Client Quit]
enitiz has joined #ocaml
darth_lumbergh has joined #ocaml
paradoja has joined #ocaml
Algebr has joined #ocaml
Algebr has quit [Remote host closed the connection]
BitPuffin has joined #ocaml
ggole has joined #ocaml
Sim_n has joined #ocaml
Simn has quit [Ping timeout: 252 seconds]
destrius has joined #ocaml
ygrek has joined #ocaml
ptc has joined #ocaml
ptc is now known as Guest28309
axiles has joined #ocaml
Guest28309 has quit [Client Quit]
leowzukw has quit [Ping timeout: 246 seconds]
tobiasBora has quit [Ping timeout: 252 seconds]
enitiz has quit [Ping timeout: 245 seconds]
ghostpl has quit [Remote host closed the connection]
ghostpl has joined #ocaml
ghostpl has quit [Remote host closed the connection]
Sim_n is now known as Simn
leowzukw has joined #ocaml
tobiasBora has joined #ocaml
darkf has quit [Quit: Leaving]
uris77 has joined #ocaml
enitiz has joined #ocaml
struktured has quit [Ping timeout: 245 seconds]
jgjl has joined #ocaml
bytbox has joined #ocaml
kapil__ has quit [Quit: Connection closed for inactivity]
tane has joined #ocaml
ollehar has joined #ocaml
ptc_ has joined #ocaml
ollehar has quit [Ping timeout: 264 seconds]
bytbox has quit [Remote host closed the connection]
bytbox has joined #ocaml
bytbox has quit [Remote host closed the connection]
rossberg has quit [Remote host closed the connection]
tel has joined #ocaml
Algebr has joined #ocaml
enitiz has quit [Ping timeout: 245 seconds]
<Algebr> I keep getting an issue with ocsigen not being able to find dllsll_threads_stubs. I have tried with leaving opam in $HOME, and now have moved it to /usr/lib/opam. I know where dllsll_stubs.so is, it does exist. Kind of stumped atm.
paradoja has left #ocaml ["Killed buffer"]
ghostpl has joined #ocaml
rossberg has joined #ocaml
enitiz has joined #ocaml
ghostpl has quit [Remote host closed the connection]
jgjl has quit [Read error: Connection reset by peer]
ygrek has quit [Ping timeout: 245 seconds]
avsm has joined #ocaml
enitiz has quit [Ping timeout: 245 seconds]
<Drup> Algebr: is it on os X or arch (or both ?)
ygrek has joined #ocaml
<Algebr> I haven't tried on OS X, just on Arch
<Drup> ok
destrius has quit [Quit: Leaving.]
ghostpl has joined #ocaml
avsm has quit [Client Quit]
<Drup> I don't really know, sorry. I don't think it's directly related to ocsigen (maybe lwt) so try there
<Algebr> =/
ghostpl has quit [Ping timeout: 256 seconds]
tani has joined #ocaml
rgrinberg has joined #ocaml
tane has quit [Ping timeout: 244 seconds]
<whitequark> Algebr: try setting CAML_LD_LIBRARY_PATH
<Algebr> Drup: Where would ocsigenserver expect to find .sos?
<Drup> ocsigen just uses ocamlfind
mort___ has quit [Ping timeout: 245 seconds]
ghostpl has joined #ocaml
skinkitten has joined #ocaml
ghostpl has quit [Remote host closed the connection]
ghostpl has joined #ocaml
ghostpl_ has joined #ocaml
ghostpl has quit [Read error: Connection reset by peer]
bytbox has joined #ocaml
rgrinberg has quit [Quit: Leaving.]
rgrinberg has joined #ocaml
<Algebr> Drup: But when ocsigenserver craps out, where was it expecting to find dllsll_threads_stubs.so? What can I feed to ocamlfind to simulate what would need dllssl_threads_stubs?
tani has quit [Read error: Connection reset by peer]
swgillespie has joined #ocaml
<dsheets_> Algebr, is it in ~/.opam/YOUR_SWITCH/lib/stublibs?
<Algebr> I do have this .so
<Algebr> right now I'm trying to cp it to various places that I think ocsigen would like, at least to get something working.
enitiz has joined #ocaml
paddymahoney has joined #ocaml
paddymahoney has quit [Max SendQ exceeded]
bytbox has quit [Remote host closed the connection]
<dsheets_> Algebr, you're sure it's in the stublibs for your current opam switch and you've updated your env with "eval `opam config env`"?
ggole has quit []
tane has joined #ocaml
<Algebr> yep, and did it again just now for good measure
leowzukw has quit [Quit: Lost terminal]
yomimono has quit [Ping timeout: 265 seconds]
<dsheets_> Algebr, and cat `ocamlfind printconf ldconf` points to the stublibs dir?
<Algebr> yep
<dsheets_> Could you pastebin the error?
enitiz has quit [Ping timeout: 265 seconds]
axiles has quit [Ping timeout: 252 seconds]
<dsheets_> Algebr, has CAML_LD_LIBRARY_PATH been set to something crazy? Other than that, it's probably time to raise on issue on an ocsigen tracker.
<Algebr> its set to /usr/lib/opam/4.02.1/lib, for good measure I set LD_LIBRARY_PATH as well since the readme says LD and not CAML_LD
<Algebr> I don't understand how make test.byte works though.
<dsheets_> Algebr, is that where you installed opam? ocaml/opam isn't generally relocatable.
<dsheets_> read the makefile?
<Algebr> I did read the makefile
<Algebr> been adding @echos...
<Algebr> yea, that's where I installed opam
slash^ has joined #ocaml
enitiz has joined #ocaml
ghostpl_ has quit [Remote host closed the connection]
dario_ has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
Hannibal_Smith has joined #ocaml
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jwatzman|work has joined #ocaml
rgrinberg has quit [Quit: Leaving.]
<lambdahands> Hey all, I'm using Core.Std for a list of lists transformation, and coming from Clojure I'm missing the `mapv` function. Is this implementation okay? And if so, would it be worth sending off a pull request? :) https://gist.github.com/lambdahands/603f16297bd171c05002
<nicoo> lambdahands: What is mapv supposed to do ?
<lambdahands> It takes a list of lists and runs a function over a list containing the nth element of all lists. So: `mapv [[1;2;3]; [1;2;3]] ~f:(List.fold ~f:(+)) = [2;4;6]
<lambdahands> nicoo ^
<lambdahands> nicoo: Here's the Clojure doc: http://clojuredocs.org/clojure.core/mapv - it's overloaded to accept variable length args, but I'm not sure if there's an equivalent technique in OCaml.
rgrinberg has joined #ocaml
ontologiae has quit [Ping timeout: 250 seconds]
<nicoo> is probably what you want
<nicoo> If you want (f: 'a -> 'a) and a 'a list list, you can fold with map2
badkins has quit []
<lambdahands> I believe mapv is (f: 'a list -> 'a) and 'a list list - so think of it as mapping over the "columns" in a list of "rows".
ygrek has quit [Ping timeout: 250 seconds]
<def`> lambdahands: the problem is that typing mapv would require a quite complex type system
<def`> (unless all your lists have the same type)
ptc_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<lambdahands> Ah, yes, I'm thinking of lists only with the same type. Having many types would be pretty complex. :P
Haudegen has quit [Ping timeout: 250 seconds]
tane has quit [Ping timeout: 246 seconds]
tane has joined #ocaml
jonludlam has quit [Ping timeout: 252 seconds]
<nicoo> def`: It would only require 2 GADTs, right ?
<def`> nicoo: yep, (specialized on list types in absence of higher-kinded types)
Haudegen has joined #ocaml
<def`> and would be quite inconvenient syntactically…
* nicoo nods
<def`> in the end, that's just an encoding where you provide the type witness :)
<nicoo> lambdahands: Well, I still don't get what mapv is meant to do, then
<nicoo> def`: Exactly. Also, can I have implicits, ocaml-ty and a pony ?
<def`> (following Oleg, you can also encode that with simple functions and composition I guess)
uris77 has quit [Quit: leaving]
<def`> nicoo: :D, implicits, maybe. ocaml-ty, I would like that too :D
<nicoo> \o/
<nicoo> And the pony ? :3
travisbrady has joined #ocaml
<dmbaturin> nicoo: But camels are better than ponies.
<nicoo> dmbaturin: I have a pet (O)Caml any time I want :3
q66 has joined #ocaml
<dmbaturin> On the other hand, pony is, in a sense, a horse light; while real-world camel light doesn't exist.
MrScout has joined #ocaml
MrScout has quit [Read error: Connection reset by peer]
MrScout has joined #ocaml
ontologiae has joined #ocaml
jao has joined #ocaml
jao has quit [Changing host]
jao has joined #ocaml
Kakadu has quit [Quit: Page closed]
ptc has joined #ocaml
ptc is now known as Guest14281
travisbrady has quit [Quit: travisbrady]
ontologiae has quit [Ping timeout: 245 seconds]
badkins has joined #ocaml
dsheets_ has quit [Ping timeout: 250 seconds]
enitiz has quit [Ping timeout: 245 seconds]
jao has quit [Remote host closed the connection]
shinnya has quit [Ping timeout: 252 seconds]
darth_lumbergh has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
enitiz has joined #ocaml
jao has joined #ocaml
jao has quit [Changing host]
jao has joined #ocaml
enitiz has quit [Ping timeout: 245 seconds]
travisbrady has joined #ocaml
chaptastic has joined #ocaml
ontologiae has joined #ocaml
<Algebr> why are syntax extensions so heavily used in ocaml code
<Drup> are they ?
<Drup> don't take eliom as a reference point on this =)
<seliopou> hey question about lwt.ppx. is there some special _tags incantation that's required to get it working?
<whitequark> package(lwt.ppx)
ontologiae has quit [Ping timeout: 265 seconds]
<seliopou> yeah figured... hmmmm
<seliopou> d'oh, using 2.4.5
<seliopou> upgrade time
<seliopou> thanks!
Kakadu has joined #ocaml
NoNNaN has quit [Ping timeout: 250 seconds]
Guest14281 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Algebr> What is this stuff called again [> `Foo]
<Drup> polymorphic variants
Thooms has quit [Quit: WeeChat 1.0.1]
NoNNaN has joined #ocaml
ptc has joined #ocaml
ptc is now known as Guest54826
lpw25 has joined #ocaml
bytbox has joined #ocaml
<seliopou> wow, lwt.2.4.7 requires a lot of downgrades and removals
rgrinberg has quit [Quit: Leaving.]
<whitequark> do you have aspcud installed?
dsheets has joined #ocaml
uris77 has joined #ocaml
mort___ has joined #ocaml
Muzer has quit [Excess Flood]
larhat has quit [Quit: Leaving.]
Muzer has joined #ocaml
tel has quit [Ping timeout: 265 seconds]
_andre has quit [Quit: leaving]
<seliopou> whitequark: that did wonders, thanks!
yomimono has joined #ocaml
manizzle has joined #ocaml
matason has quit [Ping timeout: 240 seconds]
rgrinberg has joined #ocaml
myst|work has quit [Ping timeout: 272 seconds]
Sorella has quit [Quit: Connection closed for inactivity]
myst|work has joined #ocaml
Algebr has quit [Remote host closed the connection]
Thooms has joined #ocaml
chinglish has quit [Quit: Nettalk6 - www.ntalk.de]
ghostpl has joined #ocaml
matason has joined #ocaml
ghostpl has quit [Ping timeout: 252 seconds]
Haudegen has quit [Ping timeout: 252 seconds]
jabesed has quit [Ping timeout: 264 seconds]
samuelrivas_ has joined #ocaml
Haudegen has joined #ocaml
myst|work has quit [Ping timeout: 245 seconds]
dsheets has quit [Ping timeout: 264 seconds]
myst|work has joined #ocaml
travisbrady has quit [Quit: travisbrady]
jave has quit [Quit: ZNC - http://znc.in]
<dch> opam problem.
<dch> I’m hacking clang support into janestreet/re2
<dch> I’ve cloned the repo locally and edited it as required, https://github.com/skunkwerks/re2 FWIW
jave has joined #ocaml
<dch> then `opam pin add -y re2 . -k git` in my source repo
dsheets has joined #ocaml
bytbox has quit [Remote host closed the connection]
travisbrady has joined #ocaml
JuggleTux has joined #ocaml
slash^ has quit [Read error: Connection reset by peer]
travisbrady has quit [Client Quit]
Thooms has quit [Ping timeout: 245 seconds]
travisbrady has joined #ocaml
nullcat has joined #ocaml
<Drup> dch: and what is the problem ? ^^'
<dch> Drup: atm its my understanding on opam pin, but its improving :-)
<dch> just hunting down more gcc-isms
travisbrady has quit [Client Quit]
Remyzorg has quit [Quit: WeeChat 1.0.1]
<dch> if I `export CXX=clang++` then re2 compiles (can’t say it passes tests yet but 1 step at a time).
<dch> but I have no more g++ left in the repo, so maybe this is an implicit gmake rule or something
* dch talks out loud
travisbrady has joined #ocaml
cateches has joined #ocaml
Thooms has joined #ocaml
* MercurialAlchemi dances the oasis/ocamlbuild danse
<Drup> MercurialAlchemi: having fun ? :D
<nicoo> dch: AFAIK, even GNU make honours ${CXX}
* nicoo dances with MercurialAlchemi
<MercurialAlchemi> after much fumbling, myocamlbuild.ml works
<MercurialAlchemi> many chickens were sacrified to the gods of build systems
<Drup> :D
<MercurialAlchemi> it's also a good illustration of the power of type systems
travisbrady has quit [Quit: travisbrady]
ghostpl has joined #ocaml
<cateches> is cohttp the recommended http library for apps that just need to have an http server built in but aren't primarily webapps? or is ocsigen more recommended
<MercurialAlchemi> for instance, when you use strings to write "ocamlep" instead of "ocamldep" and problems happen
<cateches> ocsigen seems beefier, but minsky seems to speak cohttp's praises
<nullcat> anyone wants to answer my ppx question again...?
<MercurialAlchemi> then you wish you were working in a language with a strong type system
<nullcat> whitequark sorry but are you still here?
<companion_cube> MercurialAlchemi: we should make assemblage work
matason has quit [Ping timeout: 264 seconds]
<nullcat> companion_cube do you have sometime?
<MercurialAlchemi> companion_cube: doesn't it use ocamlbuild under the covers?
travisbrady has joined #ocaml
hilquias` has joined #ocaml
tenki has joined #ocaml
<dch> nicoo: yes this is not a fix for the underlying issue in re2 though, which is hardcoded calls somewhere.
<companion_cube> MercurialAlchemi: no, it should compile to a Makefile, I think
<companion_cube> nullcat: what's your question?
<companion_cube> (can't promise I will be able to answer)
<Drup> cateches: well, ocsigen will replace most of it's internal core to cohttp soon
<rgrinberg> cateches: that depends on your app. and yeah what Drup said
<nullcat> companion_cube: i put things on repo instead of gist now. https://github.com/marklrh/ppx_playground.
<Drup> and cohttp is simpler to manipulate as a library anyway
<rgrinberg> where soon is more like sooooooooooooooooon
<tenki> hello, i am having some trouble with ocaml sets. Is it possible to make a set that can hold the values ('a,'a list)
WraithM has joined #ocaml
<nicoo> dch: You should rather send a fix for this in Google's re2, IMO
<Drup> rgrinberg: I so little time to work on that right now :x
<nullcat> still the same thing, I want to generate a function that prints the function's name
hilquias has quit [Ping timeout: 264 seconds]
<Drup> I have*
<Drup> rgrinberg: did you saw my answer for 10h ago ? :p
<rgrinberg> Drup: i have not
<companion_cube> nullcat: still the same error?
<dch> nicoo: oh cool, https://github.com/tuncer/re2/
<companion_cube> I think you should use attribute points
<dch> erlang bindings :D
<MercurialAlchemi> companion_cube: looks like you're right, at least according to the homepage
<cateches> Drup thanks I was trying out cohttp with this gist: https://gist.github.com/arjunguha/7929554 and performance was ... poor according to ab
<MercurialAlchemi> does not advertise generating 4k loc ml files
<Drup> nullcat: you read whitequark's tutorial, right ?
<nicoo> dch: Don't tell me about Erlang ;_;
<nullcat> right...
<cateches> is that a bad gist, or is that about the performance I can expect using cohttp.async
<nullcat> i asked whitequark lots of questions last night
<nullcat> 10 hours ago
<rgrinberg> cateches: you should tell us exactly how you tested the performance
* nicoo is delving in Erlang's code to figure out why their SSL module sucks so much
<rgrinberg> and we'll spend time improving it
<nullcat> companion_cube: now I just want to generate a function that can print a string called "a", https://github.com/marklrh/ppx_playground/blob/master/ppx_vb.ml#L24
<nullcat> but when you do 'make test', nothing happened. I am expecting a string "a" will be printed out
<cateches> rgrinberg `ab -n 10000 -c 100 "http://localhost"` would hang up after about ~4-5k and the server would just die
travisbrady has quit [Quit: travisbrady]
<dch> nicoo: I can tell you more about that probably.. TL;DR don’t use it if you need feature stability across releases. we (couchdb) recommend stun, haproxy etc instead.
<rgrinberg> cateches: on linx right?
<nullcat> oh i see.
<nullcat> i fixed it
<cateches> os x
matason has joined #ocaml
<companion_cube> nullcat: you need to call the function
<cateches> rgrinberg: os x
<rgrinberg> cateches: Async/Lwt are very inefficient on OSX since they use select
<companion_cube> here it looks like you just define a function p()
<nullcat> hold on, let me update my file
<rgrinberg> cateches: it's not a problem with cohttp but rather async which needs kqueue support (or be built on top of something like libuv)
<Drup> nullcat: start by using ppx_rewriter to check if the code outputed is correct
<Drup> (or the argument -dsource to the compiler)
<cateches> rgrinberg: so I can at least build working code on my MBP and trust that perfomance will be better when I'm not deploying to a cluster of MBPs ;)
<Drup> for ppx_rewriter, the CLI is "ocamlfind ppx_tools/rewriter ..."
<rgrinberg> cateches: something like that :P
<rgrinberg> cateches: but if you make any serious benchmarks please report to mirage/ocaml-cohttp
<rgrinberg> we'd happy to work on improving performance
<nicoo> dch: I'm not even an Erlang user. I'm trying to figure out why ejabberd's SSL options suck, and they are all inherited from OTP
<nullcat> Drup, thx. but my problem is not with that i guess. https://github.com/marklrh/ppx_playground/blob/master/ppx_vb.ml#L24. "p" now should print "id", which is the name of the function. I guess there is something I don't know how to do. When I do 'make test', compiler will warn me "id" is unbound
<cateches> okay, I don't need super beefy performance for a PoC, but I'll give feedback if I deploy anything and it sucks. I'm a big fan of github issues
<MercurialAlchemi> rgrinberg: it's not meant to be a front-end server, is it?
<rgrinberg> MercurialAlchemi: what is?
<MercurialAlchemi> rgrinberg: cohttp
<nicoo> But don't worry, CouchDB sucks too :þ
<nullcat> i guess i just simply insert a code that wants to print "id", but "id" is not really defined.
<dch> nicoo: we’re a friendly bunch over on #erlang feel free to ask there. or bug @old_sound on twitter too
<nicoo> 'k :)
<rgrinberg> MercurialAlchemi: depends where you run it. On mirage it mostly definitely is. On Linux i'd put nginx in front of it like most sane people
<rgrinberg> Drup: finally found your comment :D
<MercurialAlchemi> rgrinberg: isn't it susceptible to be dossed on mirage as well? or does it handle something like slowloris gracefully?
<rgrinberg> my impression of being large was looking at the ocsigen samples
<rgrinberg> like the realtime wiki
<rgrinberg> MercurialAlchemi: i believe there's no slowloris protection now. Mostly because it's something we'd like to test before claiming we're safe against it
<Drup> did you compare to a similar sized application ?
<Drup> (also, I remember you asking, and I told you I was pretty sure it wasn't minimized)
<MercurialAlchemi> rgrinberg: right
bytbox has joined #ocaml
tenki has quit [Quit: Page closed]
<Drup> nullcat: you need to antiquote before calling some ocaml
<Drup> currently, you will just output "id" literally
<Drup> do [%e id ]
<nullcat> this is the metaquot stuff in ppx_tools, right?
<nullcat> i saw that in the his comment, [%p], [%e] ...
<rgrinberg> Drup: i should reconsider it then :O. My use case is slowly getting existing JS apps out of the maintenance nightmare
<rgrinberg> which means reusing what's still there. ember/jquery etc.
chaptastic has quit []
<Drup> yeah, I understand, it's not really js_of_ocaml's strongest point since you will need to interop almost seamlesly with js. FFI with js is not big (it's much tinner than OCaml <-> C) but it's still bigger than ther other languages you considered (purescript, fay, elm)
<nullcat> can you explain it further? the [%e...] [%t ...] ... stuff?
<Drup> nullcat: are you familiar with the concept of quotation/antiquotation ?
<nullcat> not really
<nullcat> sorry... is there anything I can read and learn from?
<rgrinberg> nullcat: learn lisp :D
<rgrinberg> umm, hongbo zhang's blog talked about this stuff a little
<Drup> list is not really big on that, since everything is uniform
<Drup> nullcat: basically, you have quotations let's mark them [%str ...]
samuelrivas_ has quit [Ping timeout: 245 seconds]
yomimono has quit [Ping timeout: 264 seconds]
<Drup> inside the quotation is another language, here we have "ocaml's ast", it's not real ocaml, it's just syntactically similar
tane has quit [Quit: Verlassend]
<Drup> and sometimes, while inside an ocaml ast, you need to introduce something external (like your id) from the host language
<Drup> it's called "antiquotation" because you break out of the quotation
<Drup> normal_ocaml [%str some ocaml ast [%e normal ocaml again ] ocaml ast ]
<Drup> in case of ppx_metaquot, you have 3 different antiquotations based on which ast you want
<Drup> (expressions, patterns, types)
nullcat has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Drup> I killed him :(
* adrien sends Drup to jail
travisbrady has joined #ocaml
travisbrady has quit [Client Quit]
matason has quit [Ping timeout: 250 seconds]
uris77_ has joined #ocaml
uris77 has quit [Ping timeout: 250 seconds]
ayepot has joined #ocaml
Guest54826 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
matason has joined #ocaml
Hannibal_Smith has quit [Quit: Leaving]
jabesed has joined #ocaml
nullcat has joined #ocaml
matason has quit [Ping timeout: 250 seconds]
<nullcat> Drup no you did not. The class just ended and I have to move out and find another place
ptc has joined #ocaml
<nullcat> i see what u meant. I used LISP before but did not use too much macro.
ptc is now known as Guest74945
jwatzman|work has quit [Quit: jwatzman|work]
bytbox has quit [Remote host closed the connection]
hilquias` has quit [Ping timeout: 240 seconds]
ingsoc has quit [Read error: Connection reset by peer]
travisbrady has joined #ocaml
jonludlam has joined #ocaml
uris77_ has quit [Quit: leaving]
MercurialAlchemi has quit [Ping timeout: 245 seconds]
swgillespie has joined #ocaml
swgillespie has quit [Client Quit]
<nullcat> Drup: also it seems that [%e id] does not work. I guess it should be [%p id].
<nullcat> Drup: but there are some other problems...
<Drup> it should be [%e id]
<Drup> [%p ] is for patterns
tel has joined #ocaml
<tel> I often hear that people avoid the object system. Why is that?
<mrvn> the error messages can be strange
shinnya has joined #ocaml
<Drup> tel: you can do things differently most of the time
<tel> so it's more that it doesn't add significant power?
<Drup> it's a bit of a 2nd citizen, as it didn't received as much love as the rest of the language (in particular, it's quite slow)
<mrvn> it adds inheritance
<Drup> tel: it adds stuff, just that you don't need it all the time :)
<mrvn> if records had row types then you probably wouldn't need objects at all
<tel> mrvn: that makes a lot of sense... I often desire row types in Haskell
<mrvn> The cost of objects is that you have dynamic dispatch of methods. The extra indirection costs time.
<mrvn> which also means no inlining afaik
<seliopou> i'm getting some... "interesting" behavior while trying to pin a package
<tel> mrvn: that's good to know
<Drup> tel: note that it could be improved
<Drup> nobody dedicated time to do it, that's all
nullcat_ has joined #ocaml
<seliopou> i'm creating a replacement for the current aws package, so when I do `opam pin add aws .` locally, it's still trying to install the the package from opam rather than the local one
<tel> Drup: the performance or the semantics?
<Drup> the performance
<Drup> seliopou: opam version ?
<seliopou> 1.2.1
<nullcat_> Drup: when I use [%e id] and try to build my preprocessor, the compiler says "File "ppx_vb.ml", line 25, characters 61-63:
<nullcat_> Error: This expression has type string but an expression was expected of type
<nullcat_> Parsetree.expression"
<tel> yeah, there are good tricks for dyn dispatch optimization, but I can easily see why nobody would care enough
<mrvn> Drup: I think the main slowdown is the dynamic dispatch and you can't change that without changing the semantic or a whole lot of inlining
<Drup> tel: the semantic could also be improved though
nullcat has quit [Ping timeout: 264 seconds]
badkins has quit [Read error: Connection reset by peer]
<tel> mrvn: the "whole lot of inlining" is kind of what I think of dyn dispatch optimization in general
<Drup> nullcat_: that's because you need to build a string node
<tel> Drup: like how?
jao has quit [Ping timeout: 252 seconds]
<nullcat_> oh i see
<Drup> nullcat_: stry "Ast_convenience.str"
<Drup> try*
bytbox has joined #ocaml
<nullcat_> ok there are so much good stuff idk
<Drup> tel: the hability to inherit (you could also say "extend") an object
<Drup> currently, you can only inherit a class
<tel> Can I view information about a type in a repl?
ghostpl has quit [Remote host closed the connection]
<tel> In particular, I find myself often missing GHCi's :i
<tel> :info, :kind, etc
<whitequark> #show_type ty
<tel> oh, that apparently isn't available in utop?
<Drup> tel: just type the name of the identifier
<Drup> or use #show, but just the name is fine
<tel> Drup: maybe I have an old version, #show doesn't exist and typing the type name alone reports "Error: Unbound value list"
<Drup> you have ocaml 4.02.1 ?
<rgrinberg> tel: we have merlin in OCaml as well. which beats the pants off what's in haskell land :P
cateches has quit [Quit: Page closed]
<Drup> (and ocp-browser n__n)
<tel> Drup: yep, but utop 1.15
<Drup> (which doesn't beats hoogle, but is still damn convenient)
<tel> rgrinberg: I'm still figuring out how to use merlin :)
<Drup> tel: update, I guess.
Thooms has quit [Quit: WeeChat 1.0.1]
<tel> what's ocp-browser?
<Drup> tel: install ocp-indent and lambda-term
<rgrinberg> ocp-browser is more of an acquired taste imo :D
<def`> :)
badkins has joined #ocaml
<tel> I'm realizing suddenly that Nix's OCaml packages are a little behind across the board. Ah well, a project for another day
Kakadu has quit []
mort___ has quit [Quit: Leaving.]
<Drup> rgrinberg: what does that mean ? ^^'
<Drup> tel: don't ask yourself and use opam
mort___ has joined #ocaml
ghostpl has joined #ocaml
maufred has quit [Ping timeout: 265 seconds]
struktured has joined #ocaml
<tel> Drup: Ha, I'll think about it. Mutable package databases seem dangerous to me nowadays.
badon has quit [Quit: Leaving]
ghostpl has quit [Remote host closed the connection]
<tel> Anyway, thanks for your help everyone. I'm off for now--cheers!
tel has quit [Quit: Using Circe, the loveliest of all IRC clients]
mort___ has quit [Quit: Leaving.]
Haudegen has quit [Ping timeout: 245 seconds]
AlexRussia has quit [Ping timeout: 245 seconds]
nullcat_ has quit [Read error: Connection reset by peer]
ghostpl has joined #ocaml
Guest74945 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Haudegen has joined #ocaml
maufred has joined #ocaml
rgrinberg has quit [Quit: Leaving.]
ptc has joined #ocaml
ptc is now known as Guest67190
<seliopou> figured it out, opam file wasn't checked into the git repo
ghostpl has quit [Ping timeout: 256 seconds]
<Drup> it shouldn't have prevented the pinning
<Drup> it would have used the default opam file
travisbrady has quit [Quit: travisbrady]
badon has joined #ocaml
Simn has quit [Quit: Leaving]
swgillespie has joined #ocaml
rgrinberg has joined #ocaml
AlexRussia has joined #ocaml