ulfdoz has quit [Read error: Connection reset by peer]
Nahra_ has joined #ocaml
ttamttam has joined #ocaml
serge has joined #ocaml
q66 has joined #ocaml
ontologiae has joined #ocaml
zpe has joined #ocaml
hto has joined #ocaml
<gour>
morning
djcoin_ has joined #ocaml
<gour>
there was supposed to be presentation about wxocaml on a recent ocaml workshop in boston, but i can't see any news about it. anyone?
zpe has quit [Ping timeout: 248 seconds]
srcerer_ has joined #ocaml
srcerer has quit [Ping timeout: 268 seconds]
toolslive has quit [Ping timeout: 245 seconds]
Yoric has joined #ocaml
ygrek has joined #ocaml
ygrek_ has joined #ocaml
ygrek has quit [Ping timeout: 265 seconds]
nikki93 has quit [Remote host closed the connection]
toolslive has joined #ocaml
thomasga has joined #ocaml
ontologiae has quit [Ping timeout: 245 seconds]
mrvn has quit [Ping timeout: 248 seconds]
zpe has joined #ocaml
caligula__ has joined #ocaml
caligula_ has quit [Ping timeout: 245 seconds]
zpe has quit [Ping timeout: 240 seconds]
ontologiae has joined #ocaml
steshaw has quit [Ping timeout: 248 seconds]
zpe has joined #ocaml
zpe has quit [Ping timeout: 264 seconds]
Simn has joined #ocaml
zpe has joined #ocaml
sgnb has quit [Remote host closed the connection]
sgnb has joined #ocaml
adr has joined #ocaml
toolslive has quit [Read error: Connection timed out]
<gasche>
asmanur: in fact it's <path>.<lowerindent> where <path> is the subset of module expressions that we know how to statically reason about
ocp has joined #ocaml
<gasche>
that is <module-identifier>.<path> but also <module-identifier>(<path).<path>
<gasche>
ocp:
<gasche>
08:46 < gour> there was supposed to be presentation about wxocaml on a recent ocaml workshop in boston, but i can't see any news about it. anyone?
<gasche>
(I missed the morning talks of the OCaml workshop so I don't know)
Fusebox has quit [Read error: Connection reset by peer]
demonimin has quit [Remote host closed the connection]
demonimin has joined #ocaml
toolslive has joined #ocaml
Yoric has joined #ocaml
ygrek_ has quit [Ping timeout: 265 seconds]
darkf has quit [Quit: Leaving]
csakatok_ has quit [Ping timeout: 264 seconds]
adr has quit [Quit: Quitte]
adr has joined #ocaml
fryguybob has joined #ocaml
csakatoku has joined #ocaml
<Kakadu>
ocamlbuild question
_andre has joined #ocaml
<Kakadu>
I have a source file with tags 'use_pa_log' and 'use_pa_checked'
<Kakadu>
I have rules for ["compile"; "ocaml"; "use_pa_checked"], ["compile"; "ocaml"; "use_pa_log"] and for both. When I compile these three rules are applied
<Kakadu>
I want only third one
<Kakadu>
I want to merge to rulese because syntax extensions are order-specific
MoHaX has joined #ocaml
<nicoo>
companion_cube: Thought the same thing about delim-cc :D
ollehar has quit [Ping timeout: 248 seconds]
<jpdeplaix>
Kakadu: so you want to overwrite the flags linked to use_pa_checked and use_pa_log
<jpdeplaix>
?
<Kakadu>
probably not to override because myocamlbuild.ml is written by hands
<Kakadu>
rewrite is more suitable word
<jpdeplaix>
so, add a new flag linked with ["compile"; "ocaml"; "use_pa_checked"; "use_pa_log"] ?
<Kakadu>
In this case ["compile"; "ocaml"; "use_pa_checked"], ["compile"; "ocaml"; "use_pa_log"] will be added too
csakatoku has quit [Remote host closed the connection]
serge has quit [Remote host closed the connection]
csakatoku has joined #ocaml
csakatoku has quit [Ping timeout: 268 seconds]
<jpdeplaix>
Kakadu: you want a set of flags for use_pa_checked, use_pa_log and (use_pa_checked & use_pa_log (which doesn't includes the two previous sets of flags)) ?
<Kakadu>
yes
<Kakadu>
it seems I have done something like it but it gives me some error probably not related to ocamlbuild
<jpdeplaix>
I don't know if this is possible :/
<jpdeplaix>
Kakadu: how did you do that ?
<Kakadu>
Not exactly that: I have passed one extension in myocamlbuild and another one with _tags
adr has quit [Quit: Quitte]
<jpdeplaix>
oh yes, you can use the tag of the form: "file:yourfile.ml" and add specific flags for this
<jpdeplaix>
but anyways, you can ask gasche for a real answer
<Kakadu>
gasche, I think we should add to ocamlbuild wiki example with many syntax extensions used
<adrien_oww>
I don't know if it does exactly what you need but it's probably not very far
Kakadu_ has quit [Ping timeout: 250 seconds]
amirmc has joined #ocaml
mort___ has quit [Ping timeout: 248 seconds]
Guest87817 has quit [Remote host closed the connection]
amirmc has quit [Quit: Leaving.]
Kakadu has joined #ocaml
tane has joined #ocaml
wolfnn has joined #ocaml
amirmc has joined #ocaml
talzeus has joined #ocaml
q66_ has joined #ocaml
q66 has quit [Disconnected by services]
q66_ is now known as q66
ivan\ has quit [Ping timeout: 240 seconds]
talzeus__ has joined #ocaml
talzeus has quit [Ping timeout: 248 seconds]
ivan\ has joined #ocaml
Yoric has quit [Ping timeout: 248 seconds]
shinnya has joined #ocaml
srcerer_ is now known as srcerer
adr has joined #ocaml
mcclurmc has joined #ocaml
amirmc has quit [Quit: Leaving.]
gargaml has joined #ocaml
cesar_ has joined #ocaml
cesar_ is now known as Guest98974
Guest98974 has quit [Remote host closed the connection]
mort___ has joined #ocaml
Yoric has joined #ocaml
gargaml has quit [Quit: WeeChat 0.4.1]
ontologiae has quit [Ping timeout: 240 seconds]
mort___ has quit [Ping timeout: 248 seconds]
ttamttam has quit [Quit: ttamttam]
f[x] has joined #ocaml
mcclurmc has quit [Ping timeout: 265 seconds]
ygrek_ has quit [Ping timeout: 241 seconds]
mcclurmc has joined #ocaml
wagle has quit [Read error: Connection reset by peer]
dsheets has quit [Ping timeout: 245 seconds]
pango_ is now known as pango
wagle has joined #ocaml
chrisdotcode has joined #ocaml
Kakadu has quit [Quit: Page closed]
<ggole>
Wrong indentation bug -_-
Tamae has joined #ocaml
fryguybob has quit [Read error: Operation timed out]
fryguybob has joined #ocaml
<ollehar>
can I jump from on match case to next?
ocp has quit [Quit: Leaving.]
<gasche>
ollehar: unfortunately you can't
<ggole>
Usually you would write a function and call it in both places
<ggole>
(In a functional language, function calls are pretty much the equivalent construct to goto.)
zpe has quit [Remote host closed the connection]
djcoin_ has quit [Quit: WeeChat 0.4.1]
zpe has joined #ocaml
<ollehar>
gasche: ggole: ok, thx
ontologiae has joined #ocaml
weie has quit [Quit: Leaving...]
zpe has quit [Ping timeout: 252 seconds]
yacks has joined #ocaml
yezariaely has joined #ocaml
Drup has quit [Ping timeout: 252 seconds]
nikki93 has joined #ocaml
f[x] has quit [Ping timeout: 240 seconds]
<flux>
opam is starting to have.. unwieldy amount of packages
<flux>
I read the list from start to end and get bored before end :)
<yezariaely>
lol
<yezariaely>
time for a cleanup, then? ;-)
<flux>
I think categorization would help
<flux>
and maybe some author-provided qualificiation "mature", "beta" or possibly "alpha"..
<yezariaely>
I totally agree! Some predefined category list would be helpful, though. When people are inventing their own categories things are getting messed up.
<yezariaely>
predefined and extensible(!)
chrisdotcode has quit [Remote host closed the connection]
Drup has joined #ocaml
zpe has joined #ocaml
<flux>
I think tagging would work best with a predefined set of tags - and when they don't match, you can just put in a new one (for others to see of course)
<yezariaely>
yes, but at the beginning, there has to be a predefined set. Otherwise, you will get a bunch of similar tags with different spelling.
nikki93 has quit [Remote host closed the connection]
zpe has quit [Ping timeout: 264 seconds]
malo has quit [Quit: Leaving]
Yoric has quit [Ping timeout: 252 seconds]
szacun has joined #ocaml
<szacun>
Hi! I am taking OCam lessons on my univesity and i have just began learning and already have a problem. Can you please tell me why i got error while calling function int this code: http://pastebin.com/5kAkiVnf
olasd has quit [Quit: leaving]
<szacun>
Actually i don't know how to call function which takes more than one argument, "count elem list" also doesn't wokr
<yezariaely>
szacun: at first something about your style. Are you really taught to write functions using brackets around arguments? let rec length(list) is typically written without the brackets.
<yezariaely>
Now I will not give you the solution directly. But do you know what types are and mean?
ontologiae has quit [Ping timeout: 268 seconds]
nikki93 has joined #ocaml
olasd has joined #ocaml
<szacun>
i used to write in java, i think types are ints, doubles, strings...
<Drup>
yezariaely: I thing it's just a typo in this case :p
<flux>
yezariaely, hint: replace (elem, list) with ((elem : int), list) in the function definition's first line
<yezariaely>
Drup: I don't think so. the calls are written similarly.
<yezariaely>
flux: I wasn't looking for the solution ;-)
<flux>
oh, then szacun
<yezariaely>
I know. But I wanted to tell him/her how to annotate the functions with types.
<Drup>
yezariaely: the error is not at a call site
<yezariaely>
as you just did
<yezariaely>
Drup: I never said so.
<flux>
szacun, you may also find that often such functions in ocaml are written as let rec count elem list = .. and calls are like count 42 [42], but I suppose that's just a matter of style
<szacun>
I wrote such a function yesterday and it was working, today i really have to make some small mistake :)
<flux>
you should also see what the ocaml toplevel says the type is when you enter the function in
<flux>
it should most certainly indicate that something is wrong :)
<ggole>
szacun: else if List.hd = elem then (1 + count(elem, List.tl list)) <- spot the problem
<szacun>
ggole: here i see, i forgot about list :)
<ggole>
Yup, so it expects a list of things of the type of List.hd.
<Drup>
(as I said, probably a typo ...)
<szacun>
Changing this fixed the problem, was that all, because i got scared when you started explaining types :)
<Drup>
szacun: types are usefull to spot this kind of issues
manizzle has joined #ocaml
<Drup>
szacun: as flux said, you can know there is something wrong in your code just by looking at the type of count
milosn_ has joined #ocaml
<szacun>
Drup: you mean this: val count : ('a list -> 'a) * 'b list -> int = <fun>? That really looks strange for me, begginer
<Drup>
let's decompose it
<Drup>
val count : BLA = <fun> means that count is a function of type BLA
<Drup>
BLA, in this case, is of the form "A * B"
<Drup>
this means it's a pair of things
<Drup>
for example, (3, "a") is of type int * string
milosn has quit [Ping timeout: 248 seconds]
<szacun>
ok, i see. Do you mean, that is excepts A to be another function?
<Drup>
yes
<Drup>
obviously, in your code, "elem" shouldn't be a function
<szacun>
of course
<szacun>
anyway, thank you for everything :)
<Drup>
no problem
<Drup>
the transition Java -> Ocaml can be a bit difficult at first.
<Drup>
(but rewarding, I might say !)
Anarchos has joined #ocaml
<szacun>
The course is called "programming paradigm" i'll be taking lot's of diffrent strange(for someone used to java) languages :)
<ggole>
Does it cover things like logic programming?
<yezariaely>
szacun: What does it cover?
<szacun>
yes, will be doing logic programing after functional programming
<Drup>
logic programing is quite cool too, in it's own style
<ggole>
Great, hopefully it will be a little mind expanding
dsheets has joined #ocaml
<szacun>
yezariaely: mostly functional programming, then logic and then advanced concepts of object-oriented programming and maybe there will be time for more exotic languages like brainfuck, whitespace itd
<szacun>
have to go now, bye
Yoric has joined #ocaml
<yezariaely>
I hope that brainfuck and whitespace are not part of this ^^
<Drup>
brainfuck is quite advanced in regard to concepts of object oriented programming, isn't it ? :]
<yezariaely>
maybe there are brainfuck implementation I don't know...
<yezariaely>
+s
yezariaely has quit [Quit: Leaving.]
yezariaely has joined #ocaml
fraggle_ has quit [Remote host closed the connection]
<ggole>
How can you look at that pi example and not just melt?
<Drup>
and the gnome sort with pixel art gnomes included !
<nicoo>
Drup: Piet probaly means “awesomely beautiful” in Russian
<nicoo>
actually, it doesn't :(
<Drup>
nicoo: I will forgive you the pun, but it's actually a painter who write "interesting" compositions.
ng_ has joined #ocaml
<nicoo>
I know :o
dsheets has quit [Ping timeout: 245 seconds]
<Anarchos>
ggole you speak about the language designed after the Piet Mondrian pictures ?
<Drup>
Anarchos: yes, I just linked it
<Anarchos>
Drup could be nice for QR code !!
<Anarchos>
Drup i knew about it, but really deserve to look closer
mcclurmc has quit [Remote host closed the connection]
ng_ has quit [Quit: Leaving]
ggole has quit []
wolfnn has quit [Ping timeout: 248 seconds]
_andre has quit [Quit: leaving]
Kakadu has joined #ocaml
milosn has joined #ocaml
<Kakadu>
gasche: ping
milosn_ has quit [Ping timeout: 245 seconds]
Yoric has quit [Ping timeout: 252 seconds]
Anarchos has quit [Quit: Vision[0.9.7-H-280704]: i've been blurred!]
mcclurmc has joined #ocaml
<szacun>
I have another question, but now it's rather easy. Is there a big difference beetwen declaring function like this: "let k_3 x y z = ..." and like this: "let k_3 (x,y,z) = z"? Which is used more often? You said about types, ocaml says that this two declarations creates two diffrent types.
<Kakadu>
1st one is used more often
<Kakadu>
1st is carried function, 2nd not (more C-style function)
<Drup>
szacun: the difference is that the first function takes 3 arguments where as the second function takes *one* argument that is a triple
nikki93 has quit [Remote host closed the connection]
Snark has quit [Quit: leaving]
<Drup>
this as some consequences about the way you use the function, the first is more natural in a functional programming language since you can partially apply a function in the first form
Anarchos has joined #ocaml
<yezariaely>
Kakadu: curried, not carried
<yezariaely>
by Haskell Curry
<Drup>
szacun: you can go back and forth between the two forms, the transformation is called currification
<szacun>
ok, i'll look it up in google, thanks
<Kakadu>
yezariaely: it was spelling
<yezariaely>
ah, ok sorry then
<bernardofpc>
also, k3 (x,y,z) uses more memory because it has to *create* the triplet, whereas k3 x y z would pass the three arguments separately
<bernardofpc>
you could think of k3 (x,y,z) as equivalent to k3 (Point p)
<bernardofpc>
where k3 x y z ~~ k3(double x, double y, double z)
<bernardofpc>
*whereas
Yoric has joined #ocaml
nikki93 has joined #ocaml
pkrnj has joined #ocaml
darkf has joined #ocaml
szacun has quit []
<smondet_>
bernardofpc: I think i've read somewhere that ocamlopt will compile k3 (x,y,z) and k3 x y z to more or less the same thing (but for ocamlc it does not dothe optimization)
Anarchos has quit [Quit: sleep time]
thomasga has quit [Quit: Leaving.]
Yoric has quit [Ping timeout: 252 seconds]
Kakadu has quit []
Yoric has joined #ocaml
gour has left #ocaml []
oriba has quit [Quit: oriba]
smondet_ has quit [Quit: leaving]
smondet has joined #ocaml
caseyjames has joined #ocaml
<caseyjames>
Hi, Im gettint a "Error: Unbound module Sqlite3" when compiling but opam says "sqlite3-ocaml is already installed (current version is 2.0.4)" Any ideas whats wrong? Other opam packages are working
<Drup>
caseyjames: you need to link it during compilation
<caseyjames>
Drup: I'm just doing C-c C-b in emacs... is there a way to do it with that, or should I stop that practice?
<Drup>
I don't know this shortcut
<caseyjames>
Oh, I mean I'm just execting the buffer in toplevel. How can I go about linking it in?
<caseyjames>
Drup: do you have any tips on how I can get that linked in. I tried OCaml at the teminal with the same results. I also did ocamlfind query Sqlite3 /Users/caseybasichis/.opam/4.00.1/lib/Sqlite3
<bernardofpc>
smondet: you have a source ?
Yoric has quit [Ping timeout: 251 seconds]
<nicoo>
caseyjames, bernardofpc : I'm not convinced that looking at such micro-optimizations is worth anything :D
<caseyjames>
nicoo: what do you mean? Do you know of another way of getting it running?
<nicoo>
^^
<bernardofpc>
nicoo: well, it depends what you're doing
<bernardofpc>
if you are going to traverse a list with 1M elements, it might be better to have your function allocate the least possible
<bernardofpc>
and building a tuple is a lot of work for your garbage collector down the road
<bernardofpc>
but I look too much on %rax's
nikki93 has quit [Remote host closed the connection]
<nicoo>
bernardofpc: 1M elements is low. I would still prefer code readability
adr has quit [Quit: Quitte]
steshaw has joined #ocaml
pkrnj has quit [Quit: Computer has gone to sleep.]
<yezariaely>
I use oasis. How can I tell oasis to only build a library? ocaml setup.ml -build libname doesn't work.
<yezariaely>
(the library is defined in _oasis as libname)
<adrien>
not sure but the quick and maybe dirty way is to copy-paste the ocamlbuild command it runs and append what you need
* adrien
-> bed
<yezariaely>
thx.
<yezariaely>
How can I exclude an executable from installing when I call ocaml setup.ml -install ?
<yezariaely>
ah just found it... to tired...
<yezariaely>
+o
nikki93 has joined #ocaml
caseyjames has quit [Quit: Page closed]
caseyjames has joined #ocaml
yezariaely has quit [Quit: Leaving.]
<caseyjames>
Hi. I'm noticing that I am getting the "Unbound module" on a number of opam libraries. OUnit works, but ocamlgraph and sqlite are both giving the error. Any idea how I can get this running?
nikki93 has quit [Ping timeout: 265 seconds]
nikki93 has joined #ocaml
nikki93 has quit [Remote host closed the connection]
ollehar has quit [Ping timeout: 245 seconds]
ollehar has joined #ocaml
nikki93 has joined #ocaml
q66 has quit [Quit: Leaving]
mcclurmc has quit [Quit: Leaving.]
tane has quit [Quit: Verlassend]
technomancy has quit [Read error: Connection reset by peer]
technomancy has joined #ocaml
ng_ has joined #ocaml
nikki93 has quit [Remote host closed the connection]