Search SRILM-USER Archives

Match: Format: Sort by:
Search:

Re: Prob.h:23: parse error before `throw'

From: Andreas Stolcke <stolcke at ADDRESS HIDDEN>
Date: Wed, 08 Aug 2001 10:17:03 PDT

For now, just remove the whole 'extern "C"' construct.

--Andreas

In message <Pine.LNX.4.21.0108081607540.14371-100000 at ADDRESS HIDDEN-muenc
hen.de>you wrote:
> Hi,
>
> when I try to compile the SRILM I get the following error message:
>
>   make[2]: Entering directory `/home/weilkar/VM-LM/SRI-lm-toolkit/lm/src'
>   g++ -mcpu=i686 -Wreturn-type -DINSTANTIATE_TEMPLATES
>   -I. -I/homes/weilkar/VM-LM/SRI-lm-toolkit/include   -c -g -O2 -o
>   ../obj/i686/ngram.o ngram.cc
>   In file included from NBest.h:17,
>                    from ngram.cc:27:
>   Prob.h:23: parse error before `throw'
>
> This is caused by the follwing code-segment in Prob.h
>
>   extern "C" {
>     double atof(const char *) __THROW;
>  
>   #ifdef __THROW
>       __THROW __attribute_pure__
>   #endif
>     ; /* might be missing from math.h or stdlib.h */
>   }
>
> I am using
>   gcc version 2.95.2 19991024 (release)
>   SuSe Linux 7.0
>   Kernel 2.2.16
>   GNU libc 2.1.3
>
> What changes do I have to make to fix this problem?
>
> regards
>
> Karl
>
> ----------------------------------------------------------------------------
> Karl Weilhammer
> Institut fuer Phonetik und Sprachliche Kommunikation
> Ludwig-Maximilians-Universitaet Muenchen         Tel.: +49-(0)89-2180-2454
> Schellingstr. 3                                  Fax : +49-(0)89-2800362
> 80799 Muenchen                 Email: weilkar at ADDRESS HIDDEN
> GERMANY                        www  : http://www.phonetik.uni-muenchen.de/
> ----------------------------------------------------------------------------
>

Click here to go to the SRILM home page.