Re: ocamlopt LLVM support (Was: [Caml-list] OCamlJIT2 vs. OCamlJIT)

2010-12-06 Thread Richard Jones
case (pointers to handles) so it's not really useful for this. I do agree with the rest of your points though, and it's good to have intelligent discussion of the real issues at long last. Rich. -- Richard Jones Red Hat ___ Caml-list mai

Re: [Caml-list] Desktop GUI toolkits - current state of the art?

2010-11-26 Thread Richard Jones
syntax, how about starting a project to do something similar on top of lablgtk2? I for one would welcome this since my current project uses lablgtk2 and Gtk is a pain in the rear. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. S

Re: [Caml-list] Re: Is OCaml fast?

2010-11-23 Thread Richard Jones
ng for modern processors. I bet the C programs are doing this, except that it won't obviously be called "tuning the GC" although it amounts to precisely the same thing. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subsc

Re: [Caml-list] How does OCaml update references when values are moved by the GC?

2010-11-03 Thread Richard Jones
reading the C code of the garbage collector and sometimes the generated assembler from ocamlopt -S. It's pretty straightforward to follow. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria

Re: [Caml-list] type inference problem with Printf.sprintf ?

2010-10-27 Thread Richard Jones
internationally standardized format for dates: # Printer.Calendar.print "%F %T\n" (Calendar.now ()) ;; 2010-10-27 11:28:59 - : unit = () http://en.wikipedia.org/wiki/ISO_8601 Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscrip

Re: [Caml-list] Asynchronous IO programming in OCaml

2010-10-25 Thread Richard Jones
want to consider your whole architecture. Putting nginx or a very cut-down Apache on the front and memcached between the webserver and the database. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yqu

Re: [Caml-list] OPLP: Ocaml APache Log Parser

2010-10-13 Thread Richard Jones
bug reports are very > welcome. The code lives on github (http://github.com/cyocum/OPLP). These projects are not maintained any more but may be of interest: http://merjis.com/developers/weblogs http://merjis.com/developers/hostip Rich. -- Richard Jones Red Hat __

Re: [Caml-list] Bans in #ocaml IRC channel

2010-10-05 Thread Richard Jones
On Tue, Oct 05, 2010 at 06:54:21PM +0100, Gareth Smith wrote: > On 05/10/10 18:06, Richard Jones wrote: > > [I'm sorry this isn't really the right place to bring this up, but > > since I can't communicate on IRC, there wasn't much alternative] > > >

[Caml-list] Bans in #ocaml IRC channel

2010-10-05 Thread Richard Jones
(and the others). 18:03 < rwmjones> [I said something here] 18:03 -!- #ocaml Cannot send to channel Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives:

Re: [Caml-list] web server interface for Ocaml ( like rack, wsgi, ...)?

2010-09-21 Thread Richard Jones
em is you'll be wanting to parse parameters, cookies and the rest of it, and there it does get a little bit more complicated. I'm fairly sure ocamlnet can write standalone scripts like that? Gerd?? Rich. -- Richard Jones Red Hat ___ Caml-list ma

Re: [Caml-list] web server interface for Ocaml ( like rack, wsgi, ...)?

2010-09-19 Thread Richard Jones
offer both a concurrent/asynchronous and a direct-style > interface. Maybe I'm missing the point, but what's wrong with simply proxying the HTTP connections through your favorite webserver to the backend ocsigen/ocamlnet server? Rich. -- Richard Jones Red Hat ___

Re: [Caml-list] Re: ancient module

2010-09-14 Thread Richard Jones
On Tue, Sep 14, 2010 at 09:46:24PM +0100, Richard Jones wrote: > I've only used ancient to store simple arrays, and when we needed to > do string equality I remember writing a function which was aware of > the above issue (you can compare them byte for byte just fine, even >

[Caml-list] Re: ancient module

2010-09-14 Thread Richard Jones
the same way. They are always compared using pointer equality, so there's no issue. I've only used ancient to store simple arrays, and when we needed to do string equality I remember writing a function which was aware of the above issue (you can compare t

Re: [Caml-list] SOAP

2010-09-05 Thread Richard Jones
: Merjis' looks outdated. Well, Merjis's library needs some love, but it could be brought up to date given some time and effort. If you want to access Adwords API from OCaml I think this is your best (in fact, only) choice. Rich. -- Richard Jones Red Hat _

Re: [Caml-list] Tracking memory usage: GC output not same order as unix top command

2010-08-30 Thread Richard Jones
t;, $sum, $sum/1024/1024); print " segments:\n"; foreach (@recs) { printf ("%x-%x (%d bytes %.1f MB) %s %d\n", $_->{start}, $_->{end}, $_->{size}, $_->{size}/1024/1024, $_->{perms}, $_->{offset}); } } }

Re: [Caml-list] Tracking memory usage: GC output not same order as unix top command

2010-08-30 Thread Richard Jones
On Mon, Aug 30, 2010 at 11:02:52AM +0100, Richard Jones wrote: > On Mon, Aug 30, 2010 at 10:43:42AM +0100, Hugo Ferreira wrote: > > The output > > shows memory usage below the 100M mark, however the unix command > > "top" shows usage in the order of Gigabytes

Re: [Caml-list] Tracking memory usage: GC output not same order as unix top command

2010-08-30 Thread Richard Jones
escapes me at the moment. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.inria.fr Beginner's list: http://groups.yahoo.com/group/ocaml_beginn

Re: [Caml-list] More re GC hanging

2010-08-20 Thread Richard Jones
0 > /proc/sys/kernel/randomize_va_space > but first learn more about it. > > I believe recent Ocaml versions (did you try 3.12?) have GC improvements > for that. Would that be: https://bugzilla.redhat.com/show_bug.cgi?id=445545 (fixed in OCaml 3.11)? Rich. -- Richard Jones Red H

Re: [Caml-list] GC hangs application

2010-08-11 Thread Richard Jones
one potential solution to this. > I'm using OCaml 3.11 on Fedora 12. There are no specific issues with OCaml in Fedora 12 that I know of. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria

Re: [Caml-list] scalable web apps

2010-07-26 Thread Richard Jones
On Sun, Jul 25, 2010 at 10:56:22PM +0100, Joel Reymont wrote: > How does Ocsigen handle database operations? I thought it was using PG'OCaml, but maybe I'm wrong. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscripti

Re: [Caml-list] scalable web apps

2010-07-25 Thread Richard Jones
use, what to cache, optimizing HTML. Here are a couple I like: http://www.amazon.com/Building-Scalable-Web-Sites-Applications/dp/0596102356 http://www.amazon.com/Speed-Up-Your-Site-Optimization/dp/toc/0735713243 Rich. -- Richard Jones Red Hat ___ Caml

Re: [Caml-list] Distinguish between osx and linux programmatically

2010-07-08 Thread Richard Jones
On Thu, Jul 08, 2010 at 10:42:40AM -0500, Romain Beauxis wrote: > Le jeudi 8 juillet 2010 06:44:34, Richard Jones a écrit : > > Stdlib could bind the uname(2) syscall, but it's legendary in its > > complexity. Seems more likely to cause problems than just calling out > &g

Re: [Caml-list] Distinguish between osx and linux programmatically

2010-07-08 Thread Richard Jones
On Thu, Jul 08, 2010 at 01:09:41PM +0200, Daniel Bünzli wrote: > On Thu, Jul 8, 2010 at 12:23 PM, Richard Jones wrote: > > > How about running the external "uname" program. > > Yes, why not. I was hoping that I wouldn't have to resort to that kind > of hacks,

Re: [Caml-list] Distinguish between osx and linux programmatically

2010-07-08 Thread Richard Jones
X it prints: $ uname Darwin On all Linux distros it prints: $ uname Linux Of course, only run external "uname" if Sys.os_type = "Unix". Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://

Re: [Caml-list] adding a scripting language to an ocaml program

2010-07-06 Thread Richard Jones
e the values going between the Perl and the OCaml code, and detect errors at runtime (at compile time too in some circumstances). http://git.annexia.org/?p=perl4caml.git;a=blob;f=perl.mli;h=64d7904eb633bcc410f796d19e289bca49931bb5;hb=HEAD#l258 Your users might not thank you for this ... Ri

Re: [Caml-list] Soap client library?

2010-06-26 Thread Richard Jones
elp on the subject. I wish you luck with this. SOAP/WSDL is a crazy non standard, and the best thing to do is to add the bits you need to OC-SOAP to enable it to work against the particular service you want to use. Rich. -- Richard Jones Red Hat ___

Re: [Caml-list] Static exception analysis or alternative to using exceptions

2010-05-27 Thread Richard Jones
in all, this is not ideal for writing correct programs. Some sort of exception analysis would be most welcome. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-li

Re: [Caml-list] What should the "size" in "caml_alloc_custom" be?

2010-05-20 Thread Richard Jones
ttp://oirase.annexia.org/libguestfs-1.3.13/ocaml/ Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.inria.fr Beginner's list: htt

Re: [Caml-list] Inspect and dump values on the OCaml heap

2010-04-14 Thread Richard Jones
t I would add that such a thing exists as the 'Std.dump' function in extlib. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.inria

Re: [Caml-list] exception not registered.Abandon

2010-03-13 Thread Richard Jones
On Sat, Mar 13, 2010 at 06:55:37PM +, Richard Jones wrote: > Essentially you have to register OCaml exceptions before you can call > them from C, so it sounds like you're not calling some sort of SDL > "init" function (or calling it too late in your program). Or poss

Re: [Caml-list] exception not registered.Abandon

2010-03-13 Thread Richard Jones
s like you're not calling some sort of SDL "init" function (or calling it too late in your program). Or possibly there is a bug in the ocaml-SDL bindings. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription mana

Re: [Caml-list] exception not registered.Abandon

2010-03-13 Thread Richard Jones
is error message. > How should I interpret it? Is the program linked to C code (apart from stdlib, I mean)? AFAICT, no part of that message occurs in the OCaml codebase, although my checked out version is a few months old now. Rich. -- Richard Jones Red Hat ___

Re: [Caml-list] Shared memory parallel application: kernel threads

2010-03-13 Thread Richard Jones
-- Use MPI as an easy way to spread the jobs over the nodes and for coordinating the processes, then have each process open a shared Ancient file (backed by NFS) for the read-only data. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list

Re: [Caml-list] Shared memory parallel application: kernel threads

2010-03-13 Thread Richard Jones
r multiple machines, then OCaml MPI is probably the way to go. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.inria.fr Beginner&#x

Re: [Caml-list] OCaml Alliance Login

2010-03-05 Thread Richard Jones
any other > way to acquire an account? I think your email got eaten by my spam filter. I'll send an invite in a moment. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/

Re: [Caml-list] gc overhead

2010-03-01 Thread Richard Jones
e tried using SystemTap with userspace DTrace-compatible probes to measure anything about total kernel + userspace usage of OCaml programs? ie, this sort of thing: http://sourceware.org/systemtap/wiki/AddingUserSpaceProbingToApps but with OCaml programs. Rich

[Caml-list] OCaml bindings to hivex (Windows Registry hive library)

2010-02-25 Thread Richard Jones
hive files themselves. http://git.annexia.org/?p=hivex.git;a=blob;f=generator/generator.ml;hb=HEAD http://git.annexia.org/?p=hivex.git;a=tree;f=lib/tools;hb=HEAD Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription manage

Re: [Caml-list] OCaml/C variant representation

2010-02-24 Thread Richard Jones
# Two-elem block, second field is # another block. # Std.dump None ;; - : string = "0" # Std.dump (Some "foo") ;; - : string = "(\"foo\")" Rich. -- Richard Jones Red Hat ___ Cam

Re: [Caml-list] range of hash function

2010-02-21 Thread Richard Jones
ntation used by Perl was changed to avoid this attack: http://perl5.git.perl.org/perl.git/blob/HEAD:/perl.c#l1465 Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/cam

Re: [Caml-list] Looking for a translator for the pipes chapter of the OCaml unix course

2010-02-16 Thread Richard Jones
On Tue, Feb 16, 2010 at 06:19:04PM +0100, Daniel Bünzli wrote: > [1] http://ocamlunix.forge.ocamlcore.org/pipes.html On a completely unrelated note, that is the best looking hevea-translated TeX document I've ever seen. Is it all done through choosing a good HTML stylesheet? Rich. --

Re: [Caml-list] Wrapping var_args, or C ... in ocaml?

2010-02-14 Thread Richard Jones
for Haskell. http://www.annexia.org/tmp/Guestfs.hs.txt Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.inria.fr Beginner's list: http

Re: [Caml-list] Wrapping var_args, or C ... in ocaml?

2010-02-14 Thread Richard Jones
On Mon, Feb 15, 2010 at 12:13:17AM +0100, Guillaume Yziquel wrote: > Richard Jones a écrit : > >On Sun, Feb 14, 2010 at 11:46:10PM +0100, Guillaume Yziquel wrote: > >>Not the case. > >[etc] > > > >It would help if you were to be more specific about the fu

Re: [Caml-list] Wrapping var_args, or C ... in ocaml?

2010-02-14 Thread Richard Jones
An OCaml list is a well-defined, well-typed version of the C ellipsis isn't it? Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.

Re: [Caml-list] Wrapping var_args, or C ... in ocaml?

2010-02-14 Thread Richard Jones
On Sun, Feb 14, 2010 at 06:06:50PM +, Richard Jones wrote: > (3) A variant list of variants, or option labels A comma got dropped there somehow; it should be: A variant, list of variants, or option labels ... which hopefully makes more sense. Rich. -- Richard Jones Red

Re: [Caml-list] Wrapping var_args, or C ... in ocaml?

2010-02-14 Thread Richard Jones
d quite a tricky implementation in OCaml. (Probably best to use ksprintf to convert to a string in OCaml and then pass printw ("%s", str) in C). In libguestfs where we autogenerate bindings we avoided varargs altogether, because it's hard to map such a concept to a

Re: [Caml-list] debugging memory leaks

2010-02-02 Thread Richard Jones
7;ll put it up on > github or google code. Thanks, I think something like github / google code is a very good idea, then someone can pick it up at a later date when they need it. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscript

Re: [Caml-list] New to Ocaml

2010-02-02 Thread Richard Jones
On Mon, Feb 01, 2010 at 11:18:07PM -0500, chaithanya kr wrote: > Hi all. I am new to Ocaml. Just started learning recently. There's also a beginners group for learning OCaml: Beginner's list: http://groups.yahoo.com/group/ocaml_beginners Rich. -- Richard

Re: [Caml-list] Ocaml implementation and low level details

2010-01-28 Thread Richard Jones
ion of the GC -- you can easily use one minor heap per thread, although that is likely to just push the problem elsewhere. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/c

Re: [Caml-list] Alignment of data

2010-01-27 Thread Richard Jones
is patch is faulty or for some other unrelated reason, so YMMV. Rich. [1] http://fedoraproject.org/wiki/Architectures#Structure -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/lis

Re: [Caml-list] ANN: Objective Caml 3.11.2 released.

2010-01-20 Thread Richard Jones
On Wed, Jan 20, 2010 at 03:21:08PM +0100, Damien Doligez wrote: > It is our pleasure to celebrate the birthday of Andre-Marie Ampere > by announcing the release of OCaml version 3.11.2. Excellent news! I've built this for Fedora and RHEL 6. Rich. -- Richard Jo

Re: [Caml-list] porter's stemmer implementation

2010-01-17 Thread Richard Jones
the file or another > implementation ? The Internet Archive has it: http://web.archive.org/web/*/http://www.aarg.net/~erik/ocaml/* or: http://www.annexia.org/tmp/stemmer-0.1.0.tar.gz Sadly this code has no license information. You would have to contact the original author about that. R

Re: [Caml-list] A question about bitwise AND in a CAML SharePoint query

2010-01-14 Thread Richard Jones
or the OCaml Programming Language: http://en.wikipedia.org/wiki/OCaml Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.inria.fr Beginner&

Re: [Caml-list] [ANN] Release Candidate: 3.11.2+rc1

2010-01-11 Thread Richard Jones
On Tue, Dec 29, 2009 at 03:59:34PM +0100, Damien Doligez wrote: > It is our pleasure to announce that the release of 3.11.2 is imminent. Is there an ETA for 3.11.2? I'd very much like to include it in RHEL 6. Rich. -- Richard Jones Red Hat

Re: [Caml-list] Re: HLVM ray tracer performance

2010-01-10 Thread Richard Jones
On Sun, Jan 10, 2010 at 08:14:29PM +, Jon Harrop wrote: > on a 64-bit Linux kernel running 32-bit userland I'm assuming you mean x86 (not eg ppc64), in which case that's a very unusual choice. Any reason for this? Rich. -- Richard

Re: [Caml-list] problem creating .cma library

2010-01-09 Thread Richard Jones
bout this section. > Rule 3: When I have a Abstract_tag block used to wrap a pointer in the C > heap, it seems to me that you can just do it with a Field(v,0)= > assignment. Do you need Store_field for that? This is to do with the Remembered Set. See part 5 of the above series. Rich.

Re: [Caml-list] memory profiling

2010-01-09 Thread Richard Jones
t sure about "new heap", but the way that heap pages are tracked changed from 3.10 -> 3.11. In 3.10 a flat bitmap was used. This was unsuitable for 64 bit address spaces[1] and in 3.11 a sparse structure is used (a hash table). Rich.

[Caml-list] [ANNOUNCE] OCaml Bitstring 2.0.2

2010-01-09 Thread Richard Jones
Home page: http://code.google.com/p/bitstring/ API documentation: http://people.redhat.com/~rjones/bitstring/html/Bitstring.html Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/m

Re: [Caml-list] [ANN] Release Candidate: 3.11.2+rc1

2010-01-05 Thread Richard Jones
ake[1]: *** [world] Error 10 make[1]: Leaving directory `/home/rjones/d/fedora/cduce/devel/cduce-0.5.3/ocamlduce-3.11.2.0+rc1/ocaml-3.11.2+rc1' error: Bad exit status from /var/tmp/rpm-tmp.tnLqgK (%build) Rich. -- Richard Jones Red Hat ___ Cam

Re: [Caml-list] [ANN] Release Candidate: 3.11.2+rc1

2010-01-05 Thread Richard Jones
On Tue, Jan 05, 2010 at 06:06:38PM +0100, Stéphane Glondu wrote: > Richard Jones a écrit : > > camlp5 - When you compile, it complains it doesn't know anything about > > 3.11.2 and that this will require an upstream change. > > The first patch attached adds support for

Re: [Caml-list] [ANN] Release Candidate: 3.11.2+rc1

2010-01-05 Thread Richard Jones
On Tue, Dec 29, 2009 at 04:52:00PM +, Richard Jones wrote: > On Tue, Dec 29, 2009 at 03:59:34PM +0100, Damien Doligez wrote: > > The release candidate is available as source code at this address: > > ftp://ftp.inria.fr/INRIA/Projects/cristal/ocaml/ocaml-3.11/ocaml-3.1

Re: [Caml-list] ocaml as editor extension language

2010-01-05 Thread Richard Jones
re's a clear chain of who wrote what, and what was applied to what). Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.inri

Re: [Caml-list] Favorite OCaml editor?

2010-01-05 Thread Richard Jones
is pretty horrible compared to tuareg-mode, which you have to install separately (albeit just a apt-get/yum install away). Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/c

Re: [Caml-list] Favorite OCaml editor?

2010-01-05 Thread Richard Jones
On Tue, Jan 05, 2010 at 12:03:39AM -0600, Grant Rettke wrote: > What is your favorite editor for hacking with OCaml? emacs + tuareg-mode Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/

Re: [Caml-list] Dynamically loaded BSS not initialised to 0.

2010-01-04 Thread Richard Jones
b;f=src/libvirt_private.syms;hb=HEAD In answer to your original question, initialization of the BSS is the job of the loader (ld-linux.so(8)). OCaml just calls dlopen(3), which calls into some extremely well-tested code, so it was always going to be unlikely that BSS initialization was the probl

Re: [Caml-list] [ANN] Release Candidate: 3.11.2+rc1

2009-12-29 Thread Richard Jones
After testing this release candidate, please send a mail to > and tell us what you tested and whether > it worked. I've pushed this out to Fedora Rawhide users after some very light testing myself. If there are any major problems we should see reports from QA systems and users in a da

Re: [Caml-list] Compiling shared library with libasmrun.a

2009-12-29 Thread Richard Jones
libasmrun.a for my situation? I think you've hit this bug: http://caml.inria.fr/mantis/view.php?id=4795 Probably would get fixed faster if someone would work out the assembler hoops required to generate PIC code on x86-64 and then post a patch to the bug. Rich. --

Re: [Caml-list] Ocaml users in Leipzig

2009-12-29 Thread Richard Jones
ested in creating a user group. Users of > > other functional programming languages are of course also welcome. > > I post this here, because I would like to meet some local Ocaml users as > well who are interested in joining such user group. Anyone? Have a look here: http://cocan.or

Re: [***SPAM*** Score/Req: 10.1/8.0] Re: [***SPAM*** Score/Req: 10.1/8.0] Re: [Caml-list] Re: OCaml is broken

2009-12-29 Thread Richard Jones
h tests are pretty much useless. Also - Solaris 10 ...? That boat left a long time ago. You should really be thinking about migrating to modern operating systems run by a company with a future. Rich. -- Richard Jones Red Hat ___ Caml-

Re: [Caml-list] Re: OCaml is broken

2009-12-29 Thread Richard Jones
Grid computing): http://www.redhat.com/mrg/ and we're doing this in partnership with some very large banks. None of that is really specific to OCaml. In fact the banks tend to use Java(!) Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Su

Re: [Caml-list] Re: Recursion on React.events.

2009-12-09 Thread Richard Jones
e but understanding frp in general [...] Personally I've yet to read any comprehensible introduction to FRP. I'm interested in whether FRP can be used to write Gtk interfaces with reduced code complexity. Apparently it can, but I've no id

Re: [Caml-list] anyone got mlgame working against the latest ocamlsdl?

2009-12-06 Thread Richard Jones
lightweight - the challenge then being to organize it, making the branches searchable, navigable and possible to merge later). Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/l

What is CPAN? (was: Re: [Caml-list] Hoogle for Ocaml)

2009-12-03 Thread Richard Jones
sting source tarballs. And more inclusive - it should include *every* source tarball -- as much OCaml source as possible. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listi

Re: [Caml-list] Hoogle for Ocaml

2009-12-03 Thread Richard Jones
s. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.inria.fr Beginner's list: http://groups.yahoo.com/group/ocaml_beginners Bug

Re: [Caml-list] Embedding the ocaml runtime in a shared library on amd64/x86_64

2009-12-02 Thread Richard Jones
http://caml.inria.fr/mantis/view.php?id=3866 So I think you should open a similar bug. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.in

Re: [Caml-list] C stubs with many args.

2009-11-29 Thread Richard Jones
uch be for the bytecode stub. > > Could someone provide me with an example somewhere? In case you still have problems, you could look at the code we autogenerate in libguestfs, eg: ocaml/guestfs_c_actions.c. We generate bindings for functions that have various numbers of arguments (up to 9).

Re: [Caml-list] New: cppo, C preprocessor for OCaml

2009-11-18 Thread Richard Jones
On Wed, Nov 18, 2009 at 01:54:18AM +0100, Martin Jambon wrote: > It is my pleasure to announce the first release of cppo, an OCaml-friendly > equivalent of the C preprocessor (cpp). All I need now is a camlp4-powerful macro preprocessor for my C code ... Rich. -- Richard Jones R

Re: [Caml-list] How to write a GC for size > memory

2009-11-13 Thread Richard Jones
use manual memory allocation, on top of which you can write a more suitable GC in OCaml for your long-lived rarely-changing blocks (eg. one based on reference counting). The invariants you describe above are exactly the ones which ocaml-ancient needs. Rich. -- Richard Jones Red Hat _

Re: [Caml-list] Unboxed float tuples

2009-11-08 Thread Richard Jones
ed representation for that. I guess others have pointed out why this isn't so easy. How about a syntax extension instead to turn a vector (| a, b, c |) into { v0 = a; v1 = b; v2 = c }, and a standard type to solve the module communication problem? I'm not sure if camlp4 will let you define

Re: [Caml-list] compiling C library wrapper

2009-11-07 Thread Richard Jones
r one of our projects, eg. libvirt-ocaml, to see how we do it: http://libvirt.org/sources/ocaml/ or: http://libguestfs.org/download/ Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-b

Re: [Caml-list] Re: How to read different ints from a Bigarray?

2009-11-02 Thread Richard Jones
ticular). There are only two processor architectures that matter in the world in any practical sense, x86-64 and ARM. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/ca

Re: [Caml-list] Binding C libraries which use variable arguments (stdarg.h)

2009-11-01 Thread Richard Jones
, then: movl 4(%ebx),%eax ; load 4 bytes of data from address %ebx + 4, put in %eax lea 4(%ebx),%eax ; add %ebx + 4 and put that in %eax Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/m

Re: [Caml-list] Re: How to read different ints from a Bigarray?

2009-11-01 Thread Richard Jones
ith.html I would love to see inline assembler supported by the compiler. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.inria.fr Begi

Re: [Caml-list] Re: How to read different ints from a Bigarray?

2009-10-30 Thread Richard Jones
; access. Take a close look at bitstring. In all the cases where it can *statically* determine that accesses are on byte or larger boundaries, it does *not* do any bitfiddling but uses the most efficient, direct C calls possible. We really did spend a lot of time optimizing the bitmatch case. Rich.

Re: [Caml-list] Re: How to read different ints from a Bigarray?

2009-10-29 Thread Richard Jones
necessarily think bitstring is suitable here though because you still need to read your data into a string (or fake a string on the C heap as Olivier Andrieu mentioned). I think in this case you'd be better off just writing this part of the code in C. Rich. --

Re: [Caml-list] Camlimages integer overflows with PNG images

2009-10-16 Thread Richard Jones
a series of problems I'm intending to drop camlimages from Fedora ... unless you can assure me that an upstream release which comprehensively fixes the problems is going to appear soon. Rich. -- Richard Jones Red Hat ___ Caml-list mailing li

[Caml-list] ANNOUNCE: OCaml in Fedora and Red Hat

2009-10-16 Thread Richard Jones
edora#Package_status Red Hat Enterprise Linux (RHEL) 6 is around the corner, and there is the possibility that OCaml will be available. If you are interested in OCaml in RHEL, or in purchasing RHEL with OCaml please talk to your account manager or contact me at: < rjones redhat com > Rich.

Re: [Caml-list] Cannot access module members as unqualified

2009-10-10 Thread Richard Jones
end;; [...] > ocamlc -c Preprocessor\Preprocessor.ml The problem you have is the above code defines a module called Preprocessor.Preprocessor. Omit all the [module ... = struct] and [end;;] parts, and it will work fine. http://ocaml-tutorial.org/the_structure_of_ocaml_programs Ri

Re: [Caml-list] Constructors are not functions

2009-10-06 Thread Richard Jones
g a "give_me_the_type_of (ocaml_subexpression)" function would be awesome indeed. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http:/

Re: [Caml-list] Constructors are not functions

2009-10-06 Thread Richard Jones
sound enough semantics for partial application of > > constructors, since the solution of having to write (fun x -> Bar x) > > is much simpler. > > Can you not just say that Bar in an expression is a function (fun x -> Bar x)? This is what standard ML seems to do. Rich. --

Re: [Caml-list] Dynlink and ocamlfind for camlp4 3.11?

2009-10-04 Thread Richard Jones
Ah but wait, your META file has that patch incorporated already! I don't know -- the cygwin distribution of OCaml is broken somehow. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cg

Re: [Caml-list] Dynlink and ocamlfind for camlp4 3.11?

2009-10-04 Thread Richard Jones
rsions of findlib include the necessary correction). So you could try the patch above, or try a later version of findlib. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/ma

Re: [Caml-list] Dynlink and ocamlfind for camlp4 3.11?

2009-10-04 Thread Richard Jones
a bug in the META files that are supplied with your cygwin OCaml distribution. Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list Archives: http://caml.inria.fr

Re: [Caml-list] Dynlink and ocamlfind for camlp4 3.11?

2009-10-04 Thread Richard Jones
load of dynlink, so I tried > >ocamlfind ocamlc -package dynlink, json-static -syntax > camlp4o -o test test.ml -linkpkg Is there really a space in "dynlink, json-static". You'll need to try it without the

Re: [Caml-list] Missing the cmi files required to use toplevellib.cma

2009-10-01 Thread Richard Jones
d distribution of such tools. This is really a packaging issue. I believe that Debian already ship the compiled sources to OCaml as a separate package, mostly for this reason. (Fedora doesn't, but probably we should follow Debian in this respect). Rich. -- Richard Jones Red Hat

Re: [Caml-list] xpath or alternatives

2009-09-30 Thread Richard Jones
On Wed, Sep 30, 2009 at 04:51:01PM +0200, Alain Frisch wrote: > Richard Jones wrote: > > let devs = {{ map [xml] with > >| [[[_]]] > >| [[[_]]] -> > >[s] > >| _ -> [] }} in > > The following should work: > > let

Re: [Caml-list] xpath or alternatives

2009-09-30 Thread Richard Jones
27; ] [ [ ] [ ] ] [ [ ] [ ] [ ] ] [ [ ] [ ] ] [ [ ] [ ] ] [ ] [ ] [ [ ] ] ] ] and what the second prerr_endline prints: "" Rich. -- Richard Jones Red Hat _

Re: [Caml-list] xpath or alternatives

2009-09-30 Thread Richard Jones
On Wed, Sep 30, 2009 at 12:57:23PM +0100, Richard Jones wrote: > On Wed, Sep 30, 2009 at 04:05:03AM -0700, Dario Teixeira wrote: > > Hi, > > > > Ocamlduce has been mentioned before in this thread, but I didn't catch > > the reason why it has been discarded a

Re: [Caml-list] xpath or alternatives

2009-09-30 Thread Richard Jones
docu/1.2.0/Simplexmlparser.html Thanks - but if I understand that page correctly, then isn't it just parsing XML into a tree? Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Subscription management: http://yquem.inria.fr/cgi-bin/ma

Re: [Caml-list] xpath or alternatives

2009-09-30 Thread Richard Jones
)); My best effort, using xml-light, is around 40 lines: http://git.et.redhat.com/?p=libguestfs.git;a=blob;f=ocaml/examples/viewer.ml;h=ef6627b1b92a4fff7d4fa1fa4aca63eeffc05ece;hb=HEAD#l322 Rich. -- Richard Jones Red Hat ___ Caml-list mailing list. Su

[Caml-list] xpath or alternatives

2009-09-28 Thread Richard Jones
alain.frisch.fr/soft.html#xpath), but unfortunately this relies on the now obsolete wlex program. Is there a completely alternative way to do this? Better still, in 3 lines of code?? Rich. [1] for XML doc, see: http://libvirt.org/formatdomain.html -- Richard Jones Red Hat

  1   2   3   4   >