From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail1-relais-roc.national.inria.fr (mail1-relais-roc.national.inria.fr [192.134.164.82]) by walapai.inria.fr (8.13.6/8.13.6) with ESMTP id oBPKTX0Q000774 for ; Sat, 25 Dec 2010 21:29:33 +0100 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AvQBAFLjFU3AbSoIe2dsb2JhbACDZJIDMY4ZFQEBFiIEIK49j1oNgRODNnQEhSGLCWw X-IronPort-AV: E=Sophos;i="4.60,229,1291590000"; d="scan'208";a="93187554" Received: from einhorn.in-berlin.de ([192.109.42.8]) by mail1-smtp-roc.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-SHA; 25 Dec 2010 21:29:11 +0100 X-Envelope-From: oliver@first.in-berlin.de X-Envelope-To: Received: from first (e178032212.adsl.alicedsl.de [85.178.32.212]) (authenticated bits=0) by einhorn.in-berlin.de (8.13.6/8.13.6/Debian-1) with ESMTP id oBPKTBBX022165 for ; Sat, 25 Dec 2010 21:29:11 +0100 Received: by first (Postfix, from userid 1000) id D5279441836; Sat, 25 Dec 2010 21:29:10 +0100 (CET) Date: Sat, 25 Dec 2010 21:29:10 +0100 From: oliver@first.in-berlin.de To: caml-list@yquem.inria.fr Message-ID: <20101225202910.GB10952@siouxsie> References: <20101224040306.GA18312@siouxsie> <20101224142501.GA3936@siouxsie> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-14) X-Scanned-By: MIMEDefang_at_IN-Berlin_e.V. on 192.109.42.8 Subject: Re: [Caml-list] PCRE: Invalid_argument("Pcre.get_offset_start: illegal offset") Hi, yes, you are right, and I had tomatoes on my eyes... I looked for "get_offset_start" as exception and had Failure as thrown exception in mind, even "Invalid_argument" is the exception, which of course is documented ...and that I already wrote some lines below... It seems I had to less sleep during the last days... Sorry for the traffic that my messed tired mind created. ;) Ciao, Oliver On Sat, Dec 25, 2010 at 03:12:55PM -0500, Markus Mottl wrote: > It is documented: the API-documentation clearly says that > Invalid_argument is going to be raised if you are trying to access a > nonexistent substring, and it is being raised here. > > Regards, > Markus > > On Fri, Dec 24, 2010 at 09:25, wrote: > > On Fri, Dec 24, 2010 at 05:03:06AM +0100, oliver@first.in-berlin.de wrote: > >> Hello, > >> > >> I could not find a description in the PCRE-documentation, > >> where this error comes from. > >> > >> This does occur on my call to get_substring, > >> but get_substring has documented exceptions, > >> in case something goes wrong: > >> > >>     * Invalid_argument if n is not in the range of the number of substrings. > >>     * Not_found if the corresponding subpattern did not capture a substring. > > [...] > > > > It seems that trying to extract more substrings than are available, > > this exception is raised. > > > > This behaviour seems not to be documented. > > > > Ciao, > >   Oliver > > > > -- > > Caml-list mailing list.  Subscription management and archives: > > https://sympa-roc.inria.fr/wws/info/caml-list > > Beginner's list: http://groups.yahoo.com/group/ocaml_beginners > > Bug reports: http://caml.inria.fr/bin/caml-bugs > > > > > > > > -- > Markus Mottl        http://www.ocaml.info        markus.mottl@gmail.com