users-prolog
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: A question


From: Erick Alphonse
Subject: Re: A question
Date: Sat, 06 Dec 2003 12:12:28 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5) Gecko/20031015

Hello,

I have a doubt. I have two files c++ which include the
header file gprolog.h. Gnu-prolog supports this or is
there any problem?.

Yes, there is a problem. A workaround has been posted to the mailing list. I don't know if there is a better way to fix it.

> There are no
> longer guards preventing multiple inclusion of the lines as opposed to
> gprolog 1.2.9 (see below). I modified directly gprolog.h in the final
> include directory by copying-pasting the relevant code from gprolog
> 1.2.9, and everything compiles now (actually, this code for gprolog.h is
> generated from src/BipsPl/bc_supp.h and src/BipsPl/parse_supp.h, but
> there is a comment saying that it's more complicated this way ;)).
>
> gprolog.h version 1.2.14
>
> #ifdef PARSE_SUPP_FILE
> InfVar parse_dico_var[MAX_VAR_IN_TERM];
> int parse_nb_var;
> #else
> extern InfVar parse_dico_var[];
> extern int parse_nb_var;
> #endif
> int last_read_line;
> int last_read_col;
>
> #ifdef BC_SUPP_FILE
> int byte_len;
> #else
> extern int byte_len;
> #endif
> unsigned *byte_code;
>
> gprolog.h version 1.2.9
>
> #ifdef PARSE_SUPP_FILE
> InfVar parse_dico_var[MAX_VAR_IN_TERM];
> int parse_nb_var;
> int last_read_line;
> int last_read_col;
> #else
> extern InfVar parse_dico_var[];
> extern int parse_nb_var;
> extern int last_read_line;
> extern int last_read_col;
> #endif
>
> #ifdef BC_SUPP_FILE
> unsigned *byte_code;
> int byte_len;
> #else
> extern unsigned *byte_code;
> extern int byte_len;
> #endif





reply via email to

[Prev in Thread] Current Thread [Next in Thread]