00:26
chessguy has joined #ocaml
00:31
jcreigh has joined #ocaml
00:43
f78 has joined #ocaml
00:52
Kwisatz- has quit ["Leaving"]
01:38
fab__ has joined #ocaml
01:39
_fab has quit [Read error: 110 (Connection timed out)]
01:40
pango has quit [Remote closed the connection]
01:47
pango has joined #ocaml
02:25
jcreigh has quit ["Cuius rei demonstrationem mirabilem sane detexi. Hanc marginis exiguitas non caperet."]
02:59
pango has quit [Remote closed the connection]
03:08
pango has joined #ocaml
03:41
jcreigh has joined #ocaml
04:40
jcreigh has quit ["yawn...it's bedtime"]
04:44
pango has quit [Remote closed the connection]
04:44
pango_ has joined #ocaml
04:55
shekmalhen has joined #ocaml
05:07
Smerdyakov has quit ["Leaving"]
05:13
jewel has joined #ocaml
05:32
_jol_ has joined #ocaml
05:42
_jol_ has quit ["temci lo nu gunka"]
05:50
shekmalhen has quit ["leaving"]
06:18
_velco has joined #ocaml
06:28
smimou has joined #ocaml
06:39
f78 has quit ["Leaving"]
07:06
pango_ has quit [Remote closed the connection]
07:44
velco has joined #ocaml
07:57
mnemonic has joined #ocaml
08:03
smimou has quit ["bli"]
08:17
<
pstickne >
hello again mnemonic :)
08:34
Wild_Cat has joined #ocaml
08:39
<
mnemonic >
pstickne :)
08:39
mnemonic has quit ["leaving"]
09:10
love-pingoo has joined #ocaml
09:12
slipstream has quit [Read error: 104 (Connection reset by peer)]
09:18
slipstream has joined #ocaml
10:08
<
jewel >
how can I make a string out of one or more chars?
10:08
<
love-pingoo >
string_of_char and concat, I guess
10:08
<
jewel >
Do I have to use the <- or set operators?
10:09
<
love-pingoo >
not necessarily
10:10
<
love-pingoo >
List.concat (List.map string_of_char ['f';'o';'o'])
10:10
<
love-pingoo >
although this solution isn't efficient
10:10
<
love-pingoo >
and string_of_char actually doesn't exist.. (String.make 1) does the job, but it looks even more over-heavy now
10:11
<
jewel >
ok I'll write a loop
10:12
* love-pingoo
wrote crap anyway, List.concat isn't about strings
10:12
* love-pingoo
hides...
10:12
<
love-pingoo >
I was thinking of String.concat, which also takes a string to put between elements..
10:15
<
zvrba >
so you just give it an empty string
10:16
<
zvrba >
it's a more general case of what you need
10:17
<
love-pingoo >
yeah, but that's a lot of more-general, it may not be very efficient
10:47
finelemo1 has joined #ocaml
10:49
jewel has quit [Read error: 110 (Connection timed out)]
11:05
finelemon has quit [Read error: 113 (No route to host)]
11:11
jewel has joined #ocaml
11:19
<
zvrba >
you're unneccessarily worrying about efficiency
11:19
<
zvrba >
and assuming too much about implementation
11:38
kencausey has joined #ocaml
12:07
Wild_Cat has quit ["Leaving"]
12:07
Wild_Cat has joined #ocaml
12:21
Wild_Cat has quit ["Leaving"]
12:56
pango has joined #ocaml
13:01
_velco has quit [Read error: 145 (Connection timed out)]
13:30
mikeX has joined #ocaml
13:46
Smerdyakov has joined #ocaml
14:35
pango_ has joined #ocaml
14:41
<
flux__ >
hmh.. sometimes ocaml can be a bit too verbose. I suppose it's time to use that 'openin'-module
14:41
<
flux__ >
in 22 lines I've mentioned word 'Database' 11 times
14:42
<
flux__ >
I suppose I could make a local alias without resorting to language extensions
14:43
<
Smerdyakov >
Now how do I turn on syntax highlighting for caml-mode?
14:45
<
flux__ >
M-x font-lock-mode, assuming emacs
14:45
<
flux__ >
tuareg-mode has more colors, though
14:45
<
Smerdyakov >
No, I know that caml-mode has a separate color setting, independent of font lock.
14:46
pango has quit [Remote closed the connection]
14:56
pango_ has quit [Remote closed the connection]
14:58
pango has joined #ocaml
15:11
beschmi has joined #ocaml
15:50
jewel has quit [Read error: 110 (Connection timed out)]
15:58
smimou has joined #ocaml
16:16
love-pingoo has quit ["Leaving"]
16:17
Snark has joined #ocaml
16:22
velco has quit ["Ex-Chat"]
17:13
_velco has joined #ocaml
17:13
_velco is now known as velco
17:26
asbeta has joined #ocaml
17:26
<
asbeta >
is it legal to use ocaml (as a compiler) for proprietary closed-source software?
17:26
<
zmdkrbou >
i don't think
17:26
<
zmdkrbou >
the ocaml licence sucks
17:27
<
asbeta >
hmm... any substitutions then?
17:27
<
zmdkrbou >
hmm, + not
17:27
<
zmdkrbou >
herm sorry : the initial answer was : yes it is legal :)
17:27
<
asbeta >
hmm... why does it suck then? :)
17:28
<
zmdkrbou >
because i don't like closed-source software :)
17:28
<
pango >
asbeta: why not check yourself on the site ?
17:28
<
asbeta >
it depends on the point of view :)
17:28
<
asbeta >
pango, i'm not good in reading licenses
17:28
<
pango >
asbeta: compiler itself has some kind of QPL license
17:28
<
pango >
standard libs are under LGPL I think
17:28
<
pango >
so I think you're free to develop closed source programs
17:29
<
asbeta >
as far as i read, i thought it was legal, but some people were convincing me that it may be illegal
17:29
<
asbeta >
well, thanks :)
17:30
<
pango >
asbeta: the only way to convince yourself is to actually go read the licence
17:31
smimou has quit ["bli"]
17:31
<
beschmi >
anyone using one of the libevent bindings?
17:31
joshcryer has quit [Read error: 104 (Connection reset by peer)]
17:33
<
asbeta >
well, i think now i'm convinced :)
17:35
_jol_ has joined #ocaml
17:48
pango has quit ["brb"]
17:53
pango has joined #ocaml
17:53
_jol_ has quit ["temci lo nu citka"]
18:33
Mr_Awesome has joined #ocaml
18:34
<
Mr_Awesome >
is there a way to quickly create a .mli file from an .ml file?
18:35
<
mellum >
Mr_Awesome: ocamlc -i
18:42
<
Mr_Awesome >
ah, thanks
18:42
<
Mr_Awesome >
heh, ive been searching the docs on every other tool besides ocamlc
18:47
_jol_ has joined #ocaml
18:48
<
Mr_Awesome >
let string_of_list str_of_e delim lst = List.fold_left (fun e1 e2 -> str_of_e e1 ^ delim ^ str_of_e e2) lst;;
18:48
<
Mr_Awesome >
that evaluates to (string->string)->string->string list->string
18:48
<
Mr_Awesome >
shouldnt it be ('a->string)->string->'a list->string ?
18:52
<
beschmi >
let string_of_list str_of_e delim = List.fold_left (fun e1 e2 -> str_of_e e1 ^ delim ^ e2) ""
18:54
<
beschmi >
still wrong
18:54
<
pango >
first parameter of List.fold_left function parameter (where you used "e1") is the accumulator
18:54
<
Mr_Awesome >
forgot about that arg
18:54
<
pango >
so you apply str_of_e to the accumulator at each iteration, hence the string -> string signature
18:55
<
Mr_Awesome >
oh so its let string_of_list str_of_e delim = List.fold_left (fun e1 e2 -> e1 ^ delim str_of_e e2) "";; ?
18:55
<
Mr_Awesome >
*delim ^ str...
18:56
<
pango >
you'll get a delim at the beginning of your result string
18:56
<
pango >
not sure that's what you want
18:57
<
Mr_Awesome >
oh thats right, delim should go after str_of_e e2
18:58
<
Mr_Awesome >
thanks pango
18:58
<
pango >
then you'll get an extra delim at the end ;)
18:58
<
Mr_Awesome >
thats fine with me
19:01
<
pango >
let string_of_list str_of_e delim lst =
19:01
<
pango >
match lst with
19:01
<
pango >
| h :: q -> List.fold_left (fun acc e -> acc ^ delim ^ str_of_e e) (str_of_e h) q
19:01
<
pango >
also, if performance matters, you should check the Buffer module to avoid some string concatenations
19:02
<
Mr_Awesome >
good idea
19:02
<
Mr_Awesome >
nah, im only printing at most 7 things
19:12
<
pango >
another version:
19:12
<
pango >
let string_of_list str_of_e delim lst = String.concat delim (List.map str_of_e lst)
19:13
<
Mr_Awesome >
oh yeah, i forgot about String.concat
19:20
<
asbeta >
what's the best way of integrating ocaml with delphi or vb6? i'm thinking about using ocaml as a logical core with delphi code for visualization
19:20
EsotericMoniker has joined #ocaml
20:01
_jol_ has quit ["leaving"]
20:21
velco has quit [sterling.freenode.net irc.freenode.net]
20:27
velco has joined #ocaml
20:45
f78 has joined #ocaml
21:00
pstickne has quit [Connection timed out]
21:01
pstickne has joined #ocaml
21:17
pango has quit [Remote closed the connection]
21:22
chessguy has joined #ocaml
21:23
velco has quit ["I'm outta here ..."]
21:36
pstickne_ has joined #ocaml
21:37
pango has joined #ocaml
21:39
pstickne has quit [Connection timed out]
21:42
pstickne_ has quit [Client Quit]
21:51
chessguy has quit [Connection timed out]
21:58
Snark has quit ["Leaving"]
22:19
Carillon has joined #ocaml
22:28
Mr_Awesome has left #ocaml []
22:39
stesch has joined #ocaml
23:02
dark_light has joined #ocaml
23:19
marcelino has joined #ocaml
23:27
marcelino has quit ["Ex-Chat"]
23:35
descender has quit [Read error: 60 (Operation timed out)]
23:35
descender has joined #ocaml