Mr_Awesome has quit [Read error: 110 (Connection timed out)]
Mr_Awesome has joined #ocaml
aminorex has joined #ocaml
rwmjones has joined #ocaml
psnively has quit []
EliasAmaral has joined #ocaml
mbishop has quit [Remote closed the connection]
martin_ has joined #ocaml
martin_ has quit ["Konversation terminated!"]
martin_ has joined #ocaml
martin_ is now known as mbishop
threeve has quit []
Mr_Awesome has quit [Read error: 110 (Connection timed out)]
G has joined #ocaml
<G>
rwmjones: can you poke me when your around?
thesoko has joined #ocaml
thesoko has quit [Remote closed the connection]
thesoko has joined #ocaml
pants1 has quit [Read error: 110 (Connection timed out)]
netx has quit [Read error: 110 (Connection timed out)]
netx has joined #ocaml
netx has quit [Connection timed out]
olegfink has quit [Read error: 104 (Connection reset by peer)]
olegfink has joined #ocaml
netx has joined #ocaml
piggybox_ has joined #ocaml
piggybox has quit [Read error: 110 (Connection timed out)]
schme has quit [Connection timed out]
bluestorm has joined #ocaml
thesoko has quit [Remote closed the connection]
pango has quit [Remote closed the connection]
pango has joined #ocaml
thermoplyae has joined #ocaml
<thermoplyae>
can vals in objects be made private, or otherwise hidden from outside view?
<thermoplyae>
based on the grammar there isn't even a keyword that would make it possible, but i'll stop by again tomorrow just in case i missed someone
<thermoplyae>
it's a bit late, i suppose
thermoplyae has left #ocaml []
kelaouchi has quit [Remote closed the connection]
buluca has joined #ocaml
ita has joined #ocaml
pants1 has joined #ocaml
Abo-Marwan47 has quit [Remote closed the connection]
screwt846 has quit [Remote closed the connection]
Abo-Marwan47 has joined #ocaml
pierpa has joined #ocaml
screwt846 has joined #ocaml
skal has joined #ocaml
kelaouchi has joined #ocaml
seafoodX has joined #ocaml
seafoodX has quit []
bluestorm has quit [Remote closed the connection]
hagman has joined #ocaml
hagman has quit [Client Quit]
ygrek has joined #ocaml
pierpa has quit [Read error: 104 (Connection reset by peer)]
love-pingoo has joined #ocaml
seafoodX has joined #ocaml
mm_aa has joined #ocaml
<mm_aa>
Hello everyone!
<mm_aa>
I'm trying to switch to ocaml from Haskell, and can't get the simplies module work.
<mm_aa>
Can you help me here?
<Smerdyakov>
Never heard of "simplies."
<mm_aa>
simpliest :)
<Smerdyakov>
"Simplest"?
<mm_aa>
yep
<Smerdyakov>
Would actual be "most simple" in English
<Smerdyakov>
Anyway, always remember the first rule of IRC: don't ask to ask.
<mm_aa>
Ok. Here I go. I've got: board.mli:
<mm_aa>
module type Board =
<mm_aa>
sig type t val create : unit -> t
<mm_aa>
end;;
<mm_aa>
board.ml:
<mm_aa>
module Board =
<mm_aa>
struct type t = int array let create () = [|0; 1; 3 |]
<mm_aa>
end;;
<mm_aa>
and mail.ml:
<mm_aa>
let b = Board.create();;
<Smerdyakov>
Too much.
<Smerdyakov>
Assume only 3 lines of code at once allowed in any channel.
<Smerdyakov>
Give a URL to the code if you need more.
<Smerdyakov>
If that's all of your code, then we'd might as well continue from here without your giving a URL. Is that all the code?
<essiene>
well... its just i think solving those problems will give me some theoritical insite i may not see otherwise... but yeah.. i get your point ita
<bluestorm>
when f is around y you want g around 0
<bluestorm>
so let g x = f x - y may be what you're looking for
<essiene>
bluestorm: ok... thnx :) the statement on reverse specialization is what got me side tracked
<bluestorm>
:p
<bluestorm>
the "ugly" way to do this, wich is more a "reverse specialization" thing, is to paste your dicho_0 code while replacing each "0" with a "y"
<essiene>
lol
<bluestorm>
let dicho_0 = dicho_y 0 is essentialy doing the reverse transformation
<essiene>
btw, what is that freemind drawing? :)
<essiene>
yeah... i kept wondering why they didn't ask b first and ask me to build a from b :)
<ita>
essiene: a tool to help you students to do your homework
<bluestorm>
is saying "i'm not in school" a studentic activity ? :p
<essiene>
lol
<ita>
essiene: it is an experimental tool part caml, part c++
jlouis has quit [Remote closed the connection]
jlouis has joined #ocaml
iratsu has quit [Remote closed the connection]
pango has quit [Remote closed the connection]
pango has joined #ocaml
ygrek has quit [Remote closed the connection]
jdavis_ has joined #ocaml
<essiene>
what library can i use for networking/sockets? i want to build YAIB (yet another irc bot) in ocaml... i think i've read enough tutorials to take on a real task
<bluestorm>
hm
<bluestorm>
you can use the "low-level" socket interface of the Unix module
<bluestorm>
but there a some IRC libraries around, if you don't want to parse it yourself and do all the plumbing
smimou has joined #ocaml
<essiene>
bluestorm: at this stage i'll like to do both... build the low level one and use some higher level stuff... just to keep getting my fingers dirty and get used to how ocaml code looks like and works
<essiene>
bluestorm: cool... i just saw the Unix module now... thnx... any pointers to the IRC libraries you talked about up there?
<bluestorm>
the whole ocaml -> JVM suite seeems interesting
<jdavis_>
I'm a novice with OCaml. What kind of apps do people normally write in ocaml? Are there some links to some cool stuff that might be inspiring?
<bluestorm>
hm
<bluestorm>
compilers :-'
<bluestorm>
what kind of apps are you interested in ?
<mbishop>
Speaking of, started there yet Smerdyakov? (I know I asked this before...but I don't remember the answer)
<jdavis_>
well, aside from normal sysadmin and web stuff, I'd like a language that I can use for better integration between applications. I was thinking OCaml might be good for data transformations, etc.
<Smerdyakov>
mbishop, yes.
<mbishop>
Smerdyakov: neat!
<jdavis_>
I suppose that integration is usually a question of access to the necessary APIs more than anything else.
<bluestorm>
hm
<bluestorm>
i suppose that depends heavily on your system, actually
<bluestorm>
(and i don't think scripting is the bright side of ocaml)
<jdavis_>
bluestorm: yeah. I am a DBA, and I use relational math for pretty much all my data transformations right now, after I can get at the data.
<Smerdyakov>
bluestorm, I think the language is equipped just fine for that, mostly; just a matter of writing the proper libraries.
<jdavis_>
Smerdyakov: that looks like an interesting company. What do they use OCaml for?
<bluestorm>
making money :)
<Smerdyakov>
jdavis_, the quantitative group is committed to 100% OCaml whenever there isn't some nasty legacy restriction requiring otherwise.
<ita>
evil capitalists
<Smerdyakov>
jdavis_, so, the answer is "what you expect proprietary trading operations to write," I think.
<mbishop>
Doesn't sweeks work there too?
<Smerdyakov>
mbishop, yup.
<ita>
jdavis_: you wouldnt like going there, they rtfm the employees all day long
* ita
runs
<Smerdyakov>
ita, sounds accurate. :-)
<Smerdyakov>
No one tells you the rules at a place like Jane Street!
<bluestorm>
were you involved in the "ocaml summer of code" thing ?
<Smerdyakov>
If you want to write OCaml professionally in an existing company, it's approximately your only choice!
<Smerdyakov>
bluestorm, no.
<bluestorm>
i have looked for a website for some of the projects
<bluestorm>
but it looks like the more accurate place to look is the janestreet svn
<bluestorm>
wich is strange
<aminorex>
the other choices would be to (1) use ocaml because its the right thing to do in a specific case, at your current job, or (2) start a new company that develops in ocaml.
<aminorex>
i'm working on (1)
<Smerdyakov>
aminorex, yes, both riskier choices. :)
<bluestorm>
(3) stay in the academic part of life
<aminorex>
(3) is a subset of (1)
<jdavis_>
aminorex, what is the nature of the project that matches #1
<bluestorm>
hm
<aminorex>
state machine generation system, from natural language documents to domain models
<bluestorm>
iirc Microsoft is looking for a F#/OCaml guy to hire
<aminorex>
it's not easy, but the ocaml is making it less unpossible
<ita>
bluestorm: for device drivers :-/
<bluestorm>
:p
<ita>
bluestorm: no one would ever want to go there
<jdavis_>
I have a job guys, I'm just looking for some inspiration to get me to learn ocaml :)
<ita>
let's face it, that's a suicide
<bluestorm>
ita: looked like device driver _verification_ or something more formal
<Smerdyakov>
Microsoft is one of the undisputed coolest functional programming supporters among for-profit corporations now.
<bluestorm>
hm
<ita>
Smerdyakov: complicated job, low level problems and management constraints
<bluestorm>
you mean Microsoft Research, right ?
<ita>
sounds like a hell to me
<Smerdyakov>
ita, uncomplicated jobs tend not to be fulfilling.
<ita>
jobs with political conflicts tend not to be fulfilling either
<Smerdyakov>
What political conflict are you anticipating?
<ita>
i have a very complicated job right now, it is not fulfilling at all
<Smerdyakov>
It's a necessary, not sufficient, condition. :P
<ita>
Smerdyakov: unclear objectives, wishful thinking on features, backward compatibility
<ita>
the "do not touch this piece of code it is for compatibility with dos" syndrome
<ita>
then for functional programming it is not a silver bullet
<ita>
fp applies well for stateless stuff, but for device drivers the modelling may be really complicated
<Smerdyakov>
No, it's all done functionally.
skal has joined #ocaml
<Smerdyakov>
They're not hiring someone to write device drivers in OCaml.
<ita>
creativity under constraints tends not to be fulfilling
<aminorex>
that's in-the-box ita. if you aren't working on Windows, there's a lot more liberty than that. my own objections to microsoft as an employer are different: i like the possibility of organizational expansive success, and becoming a useful influence. microsoft is likely to be less successful over time, and the influential role of a new individual contributor has a pretty small probability of significance. i'd have to be much cocki
<aminorex>
the stock options are pretty worthless, in other words, even if you can get them.
<Smerdyakov>
If you care about such things, then you should be in the finance industry.
<aminorex>
i am
<Smerdyakov>
There ya go. :)
<aminorex>
nice call
<ita>
the finance field is usually very cold to technological innovations
<Smerdyakov>
ita, depends on what technology you mean.
* aminorex
disagrees
<Smerdyakov>
ita, innovations in financial math are pretty welcome, I think.
<aminorex>
running accounts on as/400s, yeah, that's pretty averse to innovation
<aminorex>
but i'd rather rip my lungs out with a toothpick than be in that domain, personally
<ita>
not only this, but using recent software such as oracle 10 for datamining features may be out of question (too risky)
<ita>
cobol is fine, keep on using it
<ita>
not every finance company is yours Smerdyakov
<Smerdyakov>
Still, if it's material success that is at the top of your priorities, then there's not much other choice without taking on considerable risk.
<ita>
i suggested treemaps for improving the visualization of data (instead of using stupid excel files) : rejected, too innovative
<ita>
and another dozen of good ideas were thrown to the garbage
<aminorex>
ita, sounds like you had a hard life. i hope you take out your frustrations in wildly successful entrepreneurship.
<ita>
we had to do ajax (no applets), but without ever talking about
<ita>
aminorex: a first experience in spain
<ita>
banks are very shy at new technologies, and backward compatibility is very important
<ita>
at least in france and in spain
<Smerdyakov>
ita, ah, I see your problem. You thought I was talking about banks when I said "finance." :-)
<ita>
maybe i should go to the us, but i am afraid i will find the same thing there too
<Smerdyakov>
I'm talking about proprietary trading, as hedge-fund-y as possible.
<ita>
finance ? cleaning the data is usually too hard
<ita>
Smerdyakov: just say "wall street" instead of finance
<Smerdyakov>
OK..
<Smerdyakov>
But aren't investment banks "Wall Street"?
<ita>
Smerdyakov: in the environments i have seen they do not have manuals
<ita>
performance is not a problem, so worse than java is possible
<ita>
and for the mathematical models, they do not go much further as chi-square
skal has quit [Read error: 104 (Connection reset by peer)]
buluca has joined #ocaml
<piggybox_>
I wish ocaml had a built-in prelude as haskell has
<ita>
pervasives?
<essiene>
how do i create a string buffer? i'm doing some socket stuff (yay!) and it seems Unix.recv takes a string buffer as an argument... uhh... i've not reached a point in my tutorials where there's a talk on string buffers or what not :)
<piggybox_>
pervasive is far smaller than prelude, though it's good not to pollute name space, a lot of handy helper functions are missing in ocaml.
<bluestorm>
essiene: recv use a Unix.file_descr
<bluestorm>
a Unix abstract type you can only get with Unix.socket
<essiene>
bluestorm: yeah... i've gotten thru the rest... i have created my socket... connect'd i just want to recv, so i can point my proggie at an SMTP server and see a banner :)
<bluestorm>
hm
<pango>
essiene: it uses a string ("buffer" is its role, not its type); There's also a Buffer module, but that's something different
<essiene>
bluestorm: recv is defined as file_descr -> string -> int -> int -> msg_flag list -> int
nuncanada has joined #ocaml
<pango>
essiene: check String.create in String module
<bluestorm>
you could use higher-level functions of the Unix module, that use the standard channels for i/o
<bluestorm>
( Unix.open_connection and the like )
<essiene>
bluestorm: ohhh... didn't know about that... thnx