cjeris changed the topic of #ocaml to: Discussions about the OCaml programming language | http://caml.inria.fr/
<twobitsprite>
mbishop: ocamlplanet?
<twobitsprite>
er... there are ocaml blogs?
<Smerdyakov>
Saying "er" is no good.
ppsmimou has quit [pratchett.freenode.net irc.freenode.net]
ppsmimou has joined #ocaml
<ita>
are there caml blogs ?
<mbishop>
yes
<mbishop>
Jon Harrop has "Ocaml News" or whatever, as well as an F# one, and there are quite a few people who talk about ocaml in their blogs often
<ita>
bah, f#
<mbishop>
Don't tell me you're one of those irrational microsoft haters, simply because MSR is involved? :P
ppsmimou has quit [Connection timed out]
<ita>
mbishop: while im at it, ghc sucks monkey balls
<mbishop>
heh
<pango>
I'm sure saying "monkey" is no good too ;)
<Smerdyakov>
Anyone who has negative associations with MSR outputs is safely ignored.
<ita>
who is msr once again ?
<Smerdyakov>
Microsoft Research
<Smerdyakov>
P.S.: Question marks never have spaces before them in English.
shawn__ has joined #ocaml
ita is now known as ita|zzz
<ita|zzz>
good to know
<ita|zzz>
good night
ppsmimou has joined #ocaml
<twobitsprite>
Smerdyakov: er...?
<twobitsprite>
would camlp4 be well suited to designing a language from scratch? or is it mostly good for extending/modifying the ocaml language?
<twobitsprite>
i.e. if I were to design a language using camlp4, is it probable that I'll reach a point where I might outgrow the capabilities of camlp4+ocaml?
seafood has joined #ocaml
dark_light has joined #ocaml
postalchris has quit ["Leaving."]
slipstream has joined #ocaml
slipstream-- has quit [Connection timed out]
seafood has quit [Read error: 54 (Connection reset by peer)]
pantsd has quit ["Leaving."]
Submarine has joined #ocaml
ygrek has joined #ocaml
screwt8 has quit [Read error: 104 (Connection reset by peer)]
screwt8 has joined #ocaml
ygrek has quit [Remote closed the connection]
Smerdyakov has quit ["Leaving"]
pantsd has joined #ocaml
_blackdog has quit [Remote closed the connection]
pantsd has quit ["Leaving."]
<flux>
I think that would be true only if you require a more advanced parser, such as if the language were c++
<flux>
but for rational languages.. I think it should go a very far way
Submarine has quit [Remote closed the connection]
vorago has quit [Read error: 113 (No route to host)]
vorago has joined #ocaml
rwmjones has joined #ocaml
Mr_Awesome has quit ["...and the Awesome level drops"]
<mrvn>
flux: What about higher order type systems?
<flux>
I don't know about those. but if they can be syntactically converted to ocaml, there should be no problem?
<flux>
infact, doesn't even coq use camlp4
<flux>
and it's about as high order as you can get?-)
<flux>
(well, I suppose not)
<mrvn>
The typesystem will be defined by a meta typesystem so no I guess. At least not simple.
<flux>
epigram might be too difficult for camlp4
smimram has quit ["bli"]
jlouis has joined #ocaml
jlouis has quit [Remote closed the connection]
jlouis has joined #ocaml
jlouis has quit [Remote closed the connection]
jlouis has joined #ocaml
jlouis has quit [Remote closed the connection]
Naked has joined #ocaml
Naked is now known as Hadaka
jlouis has joined #ocaml
rickardg has joined #ocaml
love-pingoo has joined #ocaml
<mattam>
Coq uses camlp4 for all its parsing needs
_blackdog has joined #ocaml
Sparkles has joined #ocaml
joelr1 has joined #ocaml
<joelr1>
rwmjones: hi rich! how do you get rid of the undefined symbols when compiling the mod_caml shared lib?
<rwmjones>
joelr1, afternoon. What undefined symbols?
<joelr1>
ocamlc -g -w s -dtypes -I /opt/local/lib/site-lib/pcre -c mod_caml_config.ml
<joelr1>
rwmjones: hmm... it doesn't look like i'm building a shared library
<rwmjones>
I thought you got this compiled yesterday?
Ai_Itai has joined #ocaml
<rwmjones>
or do these symbols not prevent it working?
<joelr1>
rwmjones: this is stage2, production deployment on solaris
<joelr1>
rwmjones: apxs -q LDFLAGS_SHLIB <- comes back empty
<joelr1>
on solaris that is
<joelr1>
i don't think that's proper
<rwmjones>
no ... just a sec
<rwmjones>
on Fedora, /usr/sbin/apxs -q LDFLAGS_SHLIB
<rwmjones>
returns nothing either
<rwmjones>
on Debian, it prints "-shared"
<joelr1>
rwmjones: but doesn't gcc need at least -shared?
<rwmjones>
not really any idea ... you could replace it with "-shared" and see what happens I s'pose
<joelr1>
yes, will do
pantsd has joined #ocaml
<joelr1>
i think the shared flag only made things worse
<joelr1>
ld: fatal: relocations remain against allocatable but non-writable sections
<joelr1>
oh, well
<G>
rwmjones: Richard Jones of fedora-devel fame?
<G>
;)
<rwmjones>
indeed G
<rwmjones>
dunno about fame though, perhaps infamy
<G>
rwmjones: ahh right, we are still working on ppc64 ;)
<joelr1>
solaris sucks
ygrek has joined #ocaml
<mrvn>
At least you don't get a segmentation fault like me
<G>
mrvn: Seg Faults are fun, come on admit it! ;)
<mrvn>
always
<G>
having to rebuild everything to not strip out debugging info so you can use gdb, is fun
<mrvn>
My problem is that ld is segfaulting.
<mrvn>
debugging binutils is horror
<joelr1>
rwmjones: i think i just made progress
Demitar_ has quit ["Ex-Chat"]
Submarine has joined #ocaml
zeroslug` has joined #ocaml
ygrek has quit [Remote closed the connection]
<joelr1>
rwmjones: rich, i seem to have apr_table_clear instead of clear_table on my system. somehow, though, when starting on a mac this doesn't present a problem. should it be table_clear instead?
<joelr1>
then again, on the mac undefined symbols are supressed
<joelr1>
rwmjones: seems like a typo to me. should be #define ap_clear_table apr_table_clear
zeroslug` is now known as zeroslug
<rwmjones>
I'm not sure about Solaris ...
<rwmjones>
but
<joelr1>
rwmjones: it seems like a clear typo. the rest of the funs in the #if APACHE2 block all start with apr_table_
<rwmjones>
symbols which don't appear in mod_caml.so should be satisfied from the main executable or -lapr
<joelr1>
rwmjones: right. except there's no apr_clear_table anywhere and there's apr_table_clear
<rwmjones>
I wouldn't expect Apache to contain typos, but ...
<rwmjones>
or is this in mod_caml?
<joelr1>
rwmjones: yep. apache_c.c
<rwmjones>
well, maybe a typo then, or maybe they moved the symbol around since Apache 2.0
ygrek has joined #ocaml
<joelr1>
ok
<joelr1>
my apache just dumped core
<joelr1>
ouch!
<joelr1>
rwmjones: how would you debug apache dumping core when loading mod_caml.so?
<rwmjones>
I would do:
<rwmjones>
gdb --args httpd -X
<joelr1>
rwmjones: what do you think of this?
<joelr1>
#0 0xfdc42777 in set_start_bits () from /opt/csw/lib/libpcre.so.0
<joelr1>
(gdb) where
<joelr1>
#0 0xfdc42777 in set_start_bits () from /opt/csw/lib/libpcre.so.0
<joelr1>
#1 0xfdc4246f in set_start_bits () from /opt/csw/lib/libpcre.so.0
<joelr1>
#2 0xfdc4246f in set_start_bits () from /opt/csw/lib/libpcre.so.0
<joelr1>
#3 0xfdc430b2 in pcre_study () from /opt/csw/lib/libpcre.so.0
<joelr1>
#4 0xfdc8ba6a in pcre_study_stub () from /opt/csw/apache2/libexec/mod_caml.so
<joelr1>
#5 0xfdca0396 in caml_interprete () from /opt/csw/apache2/libexec/mod_caml.so
<rwmjones>
ah yes, that's the pcre error
<rwmjones>
when you have different pcre libs loaded at the same time
love-pingoo has quit ["Leaving"]
<joelr1>
rwmjones: the pcre error? something well-known?
<rwmjones>
check out if Apache is linked to or has its own pcre
<joelr1>
rwmjones: how would i do that?
<joelr1>
rwmjones: ldd?
<rwmjones>
there's some sort of configure option to Apache, like ./configure --with-external-pcre or something
<rwmjones>
basically, Apache is broken because it contains its own pcre
<rwmjones>
this affects PHP too
<rwmjones>
mod_php I mean
<joelr1>
rwmjones: i didn't compile my own apache, i just used the one supplied to me. let me see what options are used on mac osx
ulfdoz has quit [Read error: 54 (Connection reset by peer)]
<joelr1>
rwmjones: there was an old version of pcre on the system. i blew that away and installed the latest in its stead
<joelr1>
rwmjones: that eliminated the core dump
ulfdoz has joined #ocaml
<joelr1>
rwmjones: and modcaml is now working on solaris x86!
<joelr1>
the wiki is next
ygrek has quit [Remote closed the connection]
<flux>
is there much performance advantage in using modcaml over using fastcgi?
<flux>
obviously there are some things a fastcgi program cannot do (talking directly to apache)..
ygrek has joined #ocaml
<joelr1>
flux: ping rwmjones
<joelr1>
i would be interested in the answer myself
<joelr1>
for me it's an issue of integration: seems much easier to deal with mod_caml than with ocamlnet
<rwmjones>
actually hindsight being a wonderful thing, there's probably not much difference, and certainly fastcgi is easier to manage because you don't have to go through all these problems linking the program with Apache
<rwmjones>
on the other hand ...
zeroslug has quit ["ERC Version 5.2 (IRC client for Emacs)"]
<rwmjones>
Apache's interface is kind of powerful, and some of the features like bucket brigades in Apache 2 are tempting (and can't really be done in fastcgi)
<flux>
I've done some apache modules for c++ (modeemi.fi/m-arkisto for one), but lately I've considered maybe fastcgi would be the way - especially as linking modcaml with apache is not trivial :)
<flux>
gotta love the speed though :)
<flux>
I'm thinking fastcgi might be a lot easier when you want to upgrade binaries or libraries, and a package manager isn't there to help you (solaris)
<esdee>
if you don't care about accessing the apache API, you just want dynamic web stuff, I find fastcgi much nicer (not just for ocaml)
<flux>
apache has a fine module system though, which allows 'composing' stuff..
<joelr1>
i'm all for fastcgi
<joelr1>
i just wish cocan wiki was ported to it :-)
<flux>
hm, does cocan wiki exploit the apache interface somehow?
<joelr1>
flux: i have no idea. i mean, i don't think so. i haven't looked closely at the code.
<joelr1>
rwmjones: how does cocan wiki interface with modcaml? would it be easy to port it to fastcgi with, say, ocamlnet?
<rwmjones>
very closely, and no
<joelr1>
flux: there's your answer
<flux>
:)
<flux>
"joelr1 the relay"
<joelr1>
:
<joelr1>
:)
<flux>
hmm.. SELECT key FROM tbl WHERE key NOT IN (SELECT foo FROM bar) should be the same as SELECT key FROM tbl WHERE key NOT IN (SELECT key FROM tbl WHERE key IN (SELECT foo FROM bar)) should be the same, right?
<flux>
yet the latter is much, much faster
<flux>
and I mean _much_: 165 ms versus 111890 ms, that's almost 700 fold increase
<rwmjones>
flux, if this is postgresql, did you compare the output of "explain select ..." for each?
<flux>
yes
<flux>
it uses bitmap heap scan with the original query
<flux>
and bitmap index scan. the other case uses index scan (I've got indices on all the involved columns)
<flux>
I'd say that's actually a bug or misfeature; might be fixed in a more recent version, I'm using 8.1.4
esdee has quit [Read error: 104 (Connection reset by peer)]
esdee has joined #ocaml
esdee has quit [Client Quit]
<rwmjones>
G ping
jlouis_ has joined #ocaml
jlouis has quit [Read error: 104 (Connection reset by peer)]
pango has quit [Remote closed the connection]
<joelr1>
rwmjones: ping
<rwmjones>
hello
<joelr1>
does this tell you anything?
<joelr1>
ERROR: permission denied for language c
<joelr1>
ERROR: must be superuser to create procedural language
<joelr1>
WARNING: no privileges could be revoked for "public"
<joelr1>
REVOKE
<joelr1>
WARNING: no privileges could be revoked for "public"
<joelr1>
REVOKE
<joelr1>
WARNING: no privileges were granted for "public"
<joelr1>
GRANT
<joelr1>
CREATE TABLE
<joelr1>
REVOKE
<joelr1>
ERROR: role "rich" does not exist
<joelr1>
rwmjones: happens when i try to load the cocanwiki schema into the db
<rwmjones>
well, I would either delete all references to user "rich" from the SQL file, or
<rwmjones>
createuser rich
<rwmjones>
obviously that user doesn't apply to you ...
<joelr1>
rwmjones: oh, that's you. indeed
<rwmjones>
as for the " permission denied for language c", probably you can ignore it
<joelr1>
rwmjones: what about the permission denied
<joelr1>
ok
pango has joined #ocaml
<joelr1>
rwmjones: thanks
joelr1 has quit []
pango- has joined #ocaml
Sparkles has quit []
Sparkles has joined #ocaml
pango has quit [Remote closed the connection]
pango- is now known as pango
cjeris has joined #ocaml
Sparkles has quit []
joelr1 has joined #ocaml
<joelr1>
rwmjones: rich, something that's unclear to me... does cocanwiki include the merjis css and images? if not then what does switching to the merjis theme do
<joelr1>
?
<rwmjones>
joelr1, no it doesn't. The "Easy Web Marketing" theme is just a theme - it's nothing to do with merjis.com
<joelr1>
rwmjones: i see now. so it's just some css that comes with cw then?
<rwmjones>
yes
<rwmjones>
have a look at templates/page_header.html
<joelr1>
fair enough, thanks
<rwmjones>
and scripts/page.ml, but the template is the most important
<joelr1>
rwmjones: ok, thanks. one more thing... i want to integrate my compiler, it's basically a form to take source code and then a page that outputs c#. i would just make it a script part of cw, right?
Smerdyakov has joined #ocaml
<rwmjones>
well, there are several ways to do it
<joelr1>
i'm all ears!
<rwmjones>
certainly, installing your form into /_bin/ is one way to go
<joelr1>
ok, and others?
<rwmjones>
at merjis we tended to go for a "pristine" approach, where we would have either separate hosts for this (eg. a http://mycompiler.example.com/ host for the compiler) or some mod_rewrite or a combination of both
<joelr1>
rwmjones: i want it to look integrated
<rwmjones>
right, so that's why you might want to use both
<joelr1>
rwmjones: hmm... why bother separating and using rewrite, etc.?
<rwmjones>
so that if cocanwiki is, say, installed as an rpm, then when you come to upgrade you don't get errors or rpm removing your other scripts
<rwmjones>
in our case we also multi-hosted with a front-end
<joelr1>
rwmjones: ok, thanks for the indepth explanation
moglum has joined #ocaml
screwt8 has quit [Remote closed the connection]
ygrek_ has joined #ocaml
ygrek has quit [Remote closed the connection]
benny has joined #ocaml
<joelr1>
rwmjones: how long have you been coding in ocaml?
benny_ has quit [Read error: 110 (Connection timed out)]
descender has joined #ocaml
<joelr1>
rwmjones: ping
<joelr1>
rwmjones: File "page.ml", line 454, characters 2-367: This expression has type int32 but is here used with type int64
<joelr1>
rwmjones: how do i fix?
<joelr1>
rwmjones: actually, that one turned out to be rather simple
<mrvn>
Does ocaml have something like 1L and 1LL for Int32 and Int64?
<hcarty>
mrvn: I think 1l is Int32
<hcarty>
Yep, it is
<hcarty>
and 1L is Int64
<Smerdyakov>
You probably meant int32, not Int32. ;)
<hcarty>
Smerdyakov: Yes, quite :-)
<mrvn>
I ment Int32.t and Int64.t which means the same.
Submarine has quit [Nick collision from services.]