<tautologico>
I remember there was talk of doing something like the haskell platform, that would be the compilers + opam + many frequently-used libraries (possibly core)
<Drup>
what would be the point compared to what we actually have with opam ?
avsm has quit [Ping timeout: 240 seconds]
<tautologico>
a single installer packaged in a form that is guaranteed to work
<Drup>
hum, ok
Simn has quit [Quit: Leaving]
<Drup>
maybe, but I don't know, I'm not interested :)
araujo has joined #ocaml
q66 has quit [Quit: Leaving]
pyon has quit [Remote host closed the connection]
tmcm has quit [Quit: tmcm]
michael_lee has joined #ocaml
zzing has joined #ocaml
testcocoon has quit [Ping timeout: 240 seconds]
lostcuaz_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
testcocoon has joined #ocaml
zzing has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
pyon has joined #ocaml
claudiuc_ has joined #ocaml
avsm has joined #ocaml
claudiuc has quit [Ping timeout: 265 seconds]
f[x] has joined #ocaml
avsm has quit [Ping timeout: 240 seconds]
claudiuc_ has quit [Remote host closed the connection]
NoNNaN has quit [Remote host closed the connection]
NoNNaN has joined #ocaml
struktured has quit [Ping timeout: 240 seconds]
divyanshu has joined #ocaml
<tautologico>
just today in this machine I wasn't able to install 3 or 4 packages
<tautologico>
it would be a lot better if there was a binary installer with them, considering they're frequently used
talzeus has quit [Read error: Connection reset by peer]
rz has quit [Quit: Ex-Chat]
BiDOrD_ has quit [Remote host closed the connection]
manizzle has quit [Ping timeout: 240 seconds]
ousado_ has joined #ocaml
ousado has quit [Ping timeout: 264 seconds]
f[x] has quit [Ping timeout: 252 seconds]
jao has joined #ocaml
jao has quit [Changing host]
jao has joined #ocaml
<tautologico>
I'm actually having a terrible experience installing ocaml and a couple of libs on this machine today... wishing there was a platform
avsm has joined #ocaml
talzeus has joined #ocaml
tlockney is now known as tlockney_away
avsm has quit [Read error: Operation timed out]
jonh has left #ocaml []
divyanshu has quit [Quit: Computer has gone to sleep.]
f[x] has joined #ocaml
<tautologico>
is there a way to use SIMD (SSE, AVX etc) instructions on ocaml programs?
avsm has joined #ocaml
tlockney_away is now known as tlockney
avsm has quit [Ping timeout: 252 seconds]
zzing has joined #ocaml
hto has quit [Ping timeout: 255 seconds]
divyanshu has joined #ocaml
rz has joined #ocaml
divyanshu has quit [Quit: Computer has gone to sleep.]
rz has quit [Quit: Ex-Chat]
manizzle has joined #ocaml
divyanshu has joined #ocaml
divyanshu has quit [Client Quit]
watermind has joined #ocaml
tlockney is now known as tlockney_away
rz has joined #ocaml
avsm has joined #ocaml
tidren has joined #ocaml
avsm has quit [Ping timeout: 240 seconds]
cantstanya has quit [Quit: k]
divyanshu has joined #ocaml
boogie has joined #ocaml
travisbrady has joined #ocaml
yacks has joined #ocaml
travisbrady has quit [Client Quit]
<ruzu>
tautologico: i'm still an ocaml newb, but a google search for "ocaml lapack" showed some potentially promising results... i know not exactly your question but it might be useful to your problem
zzing has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rz has quit [Remote host closed the connection]
ggole has joined #ocaml
tidren has quit [Remote host closed the connection]
<tautologico>
lacaml works well for linear algebra stuff, but I wanted more general SIMD support
avsm has joined #ocaml
avsm has quit [Ping timeout: 240 seconds]
siddharthv has joined #ocaml
oriba has joined #ocaml
watermind has quit [Read error: Connection reset by peer]
rz has joined #ocaml
watermind has joined #ocaml
axiles has joined #ocaml
watermind has quit [Client Quit]
angerman has joined #ocaml
manizzle has quit [Ping timeout: 255 seconds]
<f[x]>
tautologico, ocaml is high level language. compiler decides for itself when to use specific processor feature, i.e. it uses sse2 for floats iirc
<f[x]>
I believe support for most modern vector instructions is missing
<f[x]>
if you want manual control on this - drop down to C for speed-critical parts and call it from ocaml
<f[x]>
or add support into compiler
<f[x]>
there also may be some libraries that follow this route, if memory serves me right - have a look at spoc
boogie has quit [Remote host closed the connection]
<flux>
tautologico, there are opencl bindings for ocaml, if that's something you're interested in
<flux>
there are CPU backends available as opencl implementations
<ggole>
It would be nice to have a Machine.Simd module for low level programming
<ggole>
Would need a lot of compiler support though
f[x] has quit [Ping timeout: 240 seconds]
avsm has joined #ocaml
avsm has quit [Ping timeout: 255 seconds]
boogie has joined #ocaml
patojo has joined #ocaml
boogie_ has joined #ocaml
boogie has quit [Ping timeout: 268 seconds]
patojo has quit [Ping timeout: 240 seconds]
boogie_ has quit [Ping timeout: 240 seconds]
jonludlam has joined #ocaml
ddosia has joined #ocaml
claudiuc has joined #ocaml
jonludlam has quit [Ping timeout: 240 seconds]
f[x] has joined #ocaml
esden has quit [Ping timeout: 240 seconds]
finnrobi_ is now known as finnrobi
cross has quit [Ping timeout: 240 seconds]
ollehar has joined #ocaml
mbac has quit [Ping timeout: 264 seconds]
esden has joined #ocaml
mbac has joined #ocaml
avsm has joined #ocaml
ousado_ is now known as ousado
ousado has quit [Changing host]
ousado has joined #ocaml
cross has joined #ocaml
ggole has quit [Ping timeout: 268 seconds]
avsm has quit [Ping timeout: 268 seconds]
mbac has quit [Ping timeout: 255 seconds]
Yoric has joined #ocaml
mbac has joined #ocaml
Thooms has joined #ocaml
nikki93 has quit [Remote host closed the connection]
Arsenik has joined #ocaml
yacks has quit [Ping timeout: 255 seconds]
jao has quit [Ping timeout: 268 seconds]
ggole has joined #ocaml
rb__ has joined #ocaml
tautologico has quit [Quit: Connection closed for inactivity]
<rb__>
Hi, it's my first time here :-)
<rb__>
I'm working on the 99 problems, and I have a problem in the function I pasted here: http://pastie.org/8990613
<rb__>
I don't understand what the problem is in that inner function call, if anyone could help me. It must be obvious to a regular ocaml programmer
<flux>
"compess_aux Some(x) t" is the same as "compress_aux Some x t"
<flux>
you probably want "compress_aux (Some x) t"
<flux>
actually maybe not, that error would probably be different
<flux>
but it's an error regardless :)
<rb__>
flux: I thought I had tried that but apparently not as I get an error on a later call. Thanks!
* rb__
is embarassed that is was to obvious
michel_mno_afk is now known as michel_mno
<ggole>
rb__: instead of the option, it might be better to keep the previously seen element itself as an argument
<ggole>
That'll remove some of the clumsy matching there. In order to do that, you'll have to do a little preloop match to establish a nice loop invariant (eg, you have matched away the empty list and have an element to work with).
<rb__>
ggole, you're right. The None is there only one, and I can do the first call with the first element of the list. Thx for the suggestion :-)
<rb__>
I'm changing my code
ikaros has joined #ocaml
<rb__>
ggole, as you're talking about invariant, I had trouble identifying clearly what invariant to define in this case: http://pastie.org/8990626 . I had loosely defined it as "acc contains all elements seen when traversing from left to right", if you have a better suggestion, don't hesitate to let me know :-)
<ggole>
The invariant I had in mind in this case is a very simple one, that you have an element which has been seen one or more times
<ggole>
One thing to be aware of is that 99 problems is a Lisp/Prolog exercise set, so the structure of values is going to be a bit different.
<ggole>
In particular, Lisp lists and OCaml lists are not the same.
<ggole>
This is OK, you can solve either one in OCaml, you just have to be clear about which variant you are working with.
<ggole>
So flatten in OCaml goes "one level deep", roughly speaking
<ggole>
But flatten in Lisp is an arbitrarily deep tree recursion
<ggole>
(I would solve both, both are good exercises.)
<ggole>
rb__: your compress is close to identical to what I had written :)
<ggole>
(Some minor style differences only.)
<rb__>
ok. I'm using this to get some practice, and will look at the other case. I'm surprised of the similarities with the Oz language, but that's positive :-)
<rb__>
ggole, that's good news :-D
<ggole>
rb__: if you want to try with Lisp-style lists, try defining flatten over a type like type 'a deeplist = Atom of 'a | Cons of 'a deeplist * 'a deeplist;;
<rb__>
ggole, Ok, so the difference is that there can be a (Cons (Cons ...) (Cons....)), right?
<ggole>
Yes.
<ggole>
The usual OCaml list is type 'a list = Nil | Cons of 'a * 'a list
<ggole>
(Well, with different constructor names.)
<rb__>
ok
avsm has joined #ocaml
siddharthv is now known as siddharthv_away
siddharthv_away is now known as siddharthv
AltGr has joined #ocaml
adrien_o1w is now known as adrien_oww
avsm has quit [Ping timeout: 240 seconds]
wwilly has quit [Quit: Ex-Chat]
boogie has joined #ocaml
Thooms has quit [Quit: WeeChat 0.3.8]
wwilly has joined #ocaml
boogie has quit [Ping timeout: 240 seconds]
<wwilly>
bonjour
<adrien_oww>
bunnyh
<adrien_oww>
s/h//
<wwilly>
:)
Kakadu has joined #ocaml
Yoric has quit [Ping timeout: 240 seconds]
Thooms has joined #ocaml
thomasga has joined #ocaml
rand000 has joined #ocaml
<rb__>
here's an implementation of the flatten_lisp suggested by ggole : http://pastie.org/8990709 . For the record, but remarks welcome :-)
<ggole>
rb__: nice job
<ggole>
You can make it a little more simple and efficient, though
yacks has joined #ocaml
<ggole>
In the Cons case, take a look at how you are combining results from the left and right recursions. Look for a simpler way.
<ggole>
Again, apart from formatting, that's identical to what I wrote.
<rb__>
thanks for your feedback ggole! Great for learning!
<ggole>
Yeah, 99 probs is a nice little exercise set
<ggole>
Wish there were more like it.
<rb__>
projecteurler.net might be good too, but I never tried it myself
jonludlam has joined #ocaml
Simn has joined #ocaml
rand000 has quit [Ping timeout: 252 seconds]
<ggole>
The euler problems are fine, but they are a bit further away from the language if you see what I mean.
<ggole>
Still good fun though.
rand000 has joined #ocaml
<pippijn>
I didn't know conjunctive types existed in ocaml until the recent mailing list discussion
Yoric has joined #ocaml
avsm has joined #ocaml
maattdd_ has joined #ocaml
avsm has quit [Ping timeout: 252 seconds]
patojo has joined #ocaml
patojo has quit [Ping timeout: 240 seconds]
<gasche>
pippijn: that's a good thing
<gasche>
it means they're a well-isolated features, they don't attack innocent bystanders when they learn the language
<gasche>
-s
<pippijn>
:)
<pippijn>
yes
siddharthv_away is now known as siddharthv
hto has joined #ocaml
claudiuc has quit [Remote host closed the connection]
ocp has joined #ocaml
<companion_cube>
same for me, didn't know
<ggole>
Huh. What are they useful for?
<ggole>
And how do you create an expression of type [< `A of & string ]?
<companion_cube>
apparently you have to match the argument against several distinct patterns?
avsm has joined #ocaml
<ggole>
Can you do that?
<companion_cube>
let f x = match x with | `a i -> i=0 and g x = match x with | `a s -> s="foo" ;;
<companion_cube>
let h x = (f x) || (g x);;
<ggole>
I thought that function `A -> ... | `A arg -> ... is always an error
<companion_cube>
val h : [< `A of string & int ] -> bool = <fun>
<companion_cube>
it's in distinct matches apparently
<ggole>
O_o
<ggole>
Very strange.
<ggole>
Polymorphic variants are such curious creatures.
<companion_cube>
aren't they?
<companion_cube>
I have no idea how the distinction is made at runtime
<ggole>
(I've always thought that they should be like Prolog functors, with `A and `A arg being different tags. But then, I don't know SFA about type systems.)
avsm has quit [Read error: Operation timed out]
<mrvn>
companion_cube: I think the type [< `A of string & int ] isn't populated though.
<companion_cube>
oh
<mrvn>
[< 'a of class1 & class2 ] could have members though.
<companion_cube>
so & is an intersection, and of course string and int don't intersect
boogie has joined #ocaml
<mrvn>
# h (`a 1);;
<mrvn>
Error: This expression has type [> `a of int ] but an expression was expected of type [< `a of string & int ] Types for tag `a are incompatible
<companion_cube>
yes, indeed
oriba has quit [Remote host closed the connection]
<companion_cube>
so it's useful for types that are distinct, but have a non-empty intersection
<ggole>
Meaning objects and polymorphic variants?
<companion_cube>
I think so :)
<companion_cube>
and intersection of polymorphic variants is probably computable
<companion_cube>
so you can transform foo & bar into some enumeration of variants
thorsten` has quit [Read error: Operation timed out]
thorsten` has joined #ocaml
<f[x]>
yes, and then you get the ordinary polymorphic variant type and don't see this dreadful &
<ggole>
Mmm
<ggole>
let f x = (function `A | `B | `C -> true) x && (function `C | `D | `E -> true) x indeed gives me f: [< `C] -> bool as expected
<ggole>
You can get some strange types though: val f : [< `C of & 'a ] -> bool
<Kakadu>
Does anybody use emacs24 with tuareg?
<Kakadu>
have you seen Error during redisplay: (jit-lock-function 1) signaled (void-function tuareg-syntax-propertize) ?
ollehar has quit [Ping timeout: 264 seconds]
ocp has quit [Quit: Leaving.]
Thooms has quit [Quit: WeeChat 0.3.8]
avsm has joined #ocaml
avsm has quit [Ping timeout: 240 seconds]
boogie has joined #ocaml
rb__ has quit [Ping timeout: 255 seconds]
_andre has joined #ocaml
boogie has quit [Ping timeout: 240 seconds]
talzeus has quit [Remote host closed the connection]
f[x] has quit [Ping timeout: 240 seconds]
rb__newbie has joined #ocaml
rb__newbie has quit [Quit: Leaving]
zpe has joined #ocaml
thomasga has quit [Quit: Leaving.]
siddharthv is now known as siddharthv_away
boogie has joined #ocaml
boogie has quit [Ping timeout: 240 seconds]
Muzer has quit [Excess Flood]
aurynj has quit [Quit: Leaving]
Muzer has joined #ocaml
pyon has quit [Quit: see ya]
<Drup>
pippijn: you are attending/presenting at CC, right ? :)
<pippijn>
yes
<Drup>
ok, I will see you there, then. I'm in the voluntary staff
thomasga has joined #ocaml
<adrien_oww>
btw, dokuwiki is <3, etherpad lite is <3, so I guess that dokuwiki with etherpad lite is <3² (yes, that exists)
<companion_cube>
in short it's <9
<pippijn>
Drup: nice :)
<adrien_oww>
companion_cube: ;p
<Drup>
I'm wondering which workshop to attend, there is lot's of them
thomasga has quit [Ping timeout: 240 seconds]
talzeus has joined #ocaml
talzeus_ has joined #ocaml
talzeus has quit [Ping timeout: 240 seconds]
thomasga has joined #ocaml
boogie has joined #ocaml
boogie has quit [Ping timeout: 255 seconds]
darkf has quit [Quit: Leaving]
tlockney_away is now known as tlockney
claudiuc_ has joined #ocaml
<kerneis>
Drup: I attended Places a few years ago and it was cool
<kerneis>
and I have friends fond of Galop
<kerneis>
(on a completely different topic :-)
<Drup>
there is MSFP the same day, so I'm probably going to attend this one
f[x] has joined #ocaml
divyanshu has quit [Quit: Computer has gone to sleep.]
<gasche>
I planned to go to ETAPS but screwed up with the registration (I reacted too late and they didn't have student volunteers positions anymore)
<gasche>
wish you well, kerneis and Drup
claudiuc has quit [Ping timeout: 240 seconds]
<kerneis>
gasche: oh, I'm not going this year
<Drup>
gasche: well, they didn't really had some for me, I just went to the student volunteers meeting and asked if it was ok :D
shinnya has joined #ocaml
tlockney is now known as tlockney_away
jonludlam has quit [Ping timeout: 240 seconds]
rta has quit [Ping timeout: 240 seconds]
jonludlam has joined #ocaml
thomasga has quit [Quit: Leaving.]
divyanshu has joined #ocaml
rta has joined #ocaml
boogie has joined #ocaml
tlockney_away is now known as tlockney
boogie has quit [Ping timeout: 255 seconds]
willb1 has quit [Ping timeout: 240 seconds]
amirmc has joined #ocaml
freling has quit [Ping timeout: 246 seconds]
Ronan_ has joined #ocaml
willb1 has joined #ocaml
rta has quit [Ping timeout: 264 seconds]
rz has quit [Quit: Ex-Chat]
angerman has quit [Quit: Gone]
rz has joined #ocaml
Cypi has quit [Read error: Connection reset by peer]
rb__ has joined #ocaml
Cypi has joined #ocaml
travisbrady has joined #ocaml
rta has joined #ocaml
nikki93 has quit [Ping timeout: 240 seconds]
jonludlam has quit [Ping timeout: 240 seconds]
avsm has joined #ocaml
lostcuaz has joined #ocaml
travisbrady has quit [Quit: travisbrady]
<rb__>
Working further on the 99 problems, I've come up with a different solution for the slice problem. I've put both versions at http://pastie.org/8991575 . Does my version have problems compared to the suggested one?
<companion_cube>
looks good at first sight
S11001001 has joined #ocaml
S11001001 has quit [Changing host]
S11001001 has joined #ocaml
boogie has joined #ocaml
cantstanya has joined #ocaml
rand000 has quit [Quit: leaving]
maattdd_ has quit [Ping timeout: 240 seconds]
boogie has quit [Ping timeout: 240 seconds]
<rb__>
ok, thx companion_cube
jonludlam has joined #ocaml
<companion_cube>
rb__: I guess the proposed version is pretty simple and readable
<companion_cube>
because take/drop are useful by themselves
travisbrady has joined #ocaml
travisbrady has quit [Client Quit]
zpe has quit [Remote host closed the connection]
zpe has joined #ocaml
<rb__>
companion_cube, yes indeed
shinnya has quit [Ping timeout: 268 seconds]
zpe has quit [Ping timeout: 240 seconds]
Yoric has quit [Ping timeout: 240 seconds]
jwatzman|work has joined #ocaml
lostcuaz has quit [Ping timeout: 268 seconds]
lostcuaz has joined #ocaml
Scriptonaut has joined #ocaml
<Scriptonaut>
hey guys, I'm trying to find the channel for just ml, not caml or ocaml
<Scriptonaut>
could someone direct me
<Drup>
you're not the first one to end up here, I'm not sure there is one :x
<companion_cube>
maybe there's a #sml channel
<companion_cube>
or ##sml
<Scriptonaut>
oh there is
<companion_cube>
otoh OCaml is definitely the most alive and modern variant of ML ;)
<Scriptonaut>
well I'm taking a class where we build a compiler in ml
<Scriptonaut>
ocaml is different enough that this channel probably wouldn't be much help right?
<Scriptonaut>
I've never used ml or any of it's dialects
travisbrady has joined #ocaml
<Drup>
the concept aren't so different, but the syntax is different enough that it's going to be confusing
<Drup>
yeah; you probably want to got to #sml
claudiuc_ has quit [Remote host closed the connection]
<Scriptonaut>
alright thanks guys
Scriptonaut has left #ocaml []
Arsenik has quit [Remote host closed the connection]
lostcuaz has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tlockney is now known as tlockney_away
amirmc1 has joined #ocaml
keen__ has joined #ocaml
keen_ has quit [Ping timeout: 240 seconds]
Thooms has joined #ocaml
amirmc has quit [Ping timeout: 240 seconds]
ocp has joined #ocaml
nikki93 has joined #ocaml
zzing has joined #ocaml
tautologico has joined #ocaml
boogie has joined #ocaml
zzing has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tlockney_away is now known as tlockney
Yoric has joined #ocaml
q66 has joined #ocaml
zpe has joined #ocaml
jonludlam has quit [Ping timeout: 240 seconds]
zpe has quit [Ping timeout: 252 seconds]
q66 has quit [Ping timeout: 252 seconds]
claudiuc has joined #ocaml
lpw25 has joined #ocaml
AltGr has left #ocaml []
q66 has joined #ocaml
q66 has quit [Changing host]
q66 has joined #ocaml
nikki93 has quit [Remote host closed the connection]
Kakadu has quit [Ping timeout: 245 seconds]
nikki93 has joined #ocaml
sgnb has quit [Remote host closed the connection]
nikki93 has quit [Remote host closed the connection]
sgnb has joined #ocaml
watermind has joined #ocaml
avsm has quit [Quit: Leaving.]
lostcuaz has joined #ocaml
lostcuaz has quit [Read error: Connection reset by peer]
ikaros has quit [Quit: Ex-Chat]
lostcuaz has joined #ocaml
lostcuaz has quit [Client Quit]
lostcuaz has joined #ocaml
lostcuaz has quit [Read error: Connection reset by peer]
lostcuaz has joined #ocaml
lostcuaz_ has joined #ocaml
nikki93 has joined #ocaml
nikki93 has quit [Remote host closed the connection]
nikki93 has joined #ocaml
lostcuaz has quit [Ping timeout: 240 seconds]
watermind has quit [Quit: Konversation terminated!]
rb__ has quit [Quit: Leaving]
avsm has joined #ocaml
avsm has quit [Quit: Leaving.]
jwatzman|work has quit [Quit: jwatzman|work]
michel_mno is now known as michel_mno_afk
amirmc1 has quit [Quit: Leaving.]
Kakadu has joined #ocaml
tlockney is now known as tlockney_away
divyanshu has quit [Quit: Computer has gone to sleep.]
lostcuaz_ has quit [Ping timeout: 268 seconds]
<tautologico>
anyone using IOCaml ?
Thooms has quit [Read error: No route to host]
nikki93 has quit [Remote host closed the connection]
Thooms has joined #ocaml
Thooms has quit [Client Quit]
Thooms has joined #ocaml
tlockney_away is now known as tlockney
lostcuaz has joined #ocaml
amirmc has joined #ocaml
amirmc has quit [Client Quit]
jwatzman|work has joined #ocaml
nikki93 has joined #ocaml
ocp has quit [Ping timeout: 245 seconds]
nikki93 has quit [Remote host closed the connection]
Simn has quit [Quit: Leaving]
gambogi has quit [Quit: leaving]
jonludlam has joined #ocaml
tlockney is now known as tlockney_away
travisbrady has quit [Quit: travisbrady]
travisbrady has joined #ocaml
dch has joined #ocaml
f[x] has quit [Ping timeout: 240 seconds]
Yoric has quit [Ping timeout: 240 seconds]
tlockney_away is now known as tlockney
divyanshu has joined #ocaml
michael_lee has quit [Remote host closed the connection]
Armael has quit [Ping timeout: 245 seconds]
Armael has joined #ocaml
Yoric has joined #ocaml
<gasche>
"just for ML" doesn't make sense
<gasche>
it's either SML or OCaml
<gasche>
"ML" does not denote a precise implemented programming language
<gasche>
even though the SML community used to pretend that it does
<ggole>
It seems to me that "ML" in that context is a term used precisely because it is ambiguous
nikki93 has joined #ocaml
f[x] has joined #ocaml
Simn has joined #ocaml
divyanshu has quit [Quit: Computer has gone to sleep.]