version 1.1, 2018/09/19 05:45:08 |
version 1.3, 2020/10/06 06:31:20 |
|
|
* DEVELOPER SHALL HAVE NO LIABILITY IN CONNECTION WITH THE USE, |
* DEVELOPER SHALL HAVE NO LIABILITY IN CONNECTION WITH THE USE, |
* PERFORMANCE OR NON-PERFORMANCE OF THE SOFTWARE. |
* PERFORMANCE OR NON-PERFORMANCE OF THE SOFTWARE. |
* |
* |
* $OpenXM$ |
* $OpenXM: OpenXM_contrib2/asir2018/parse/pvar.c,v 1.2 2020/09/27 04:35:05 noro Exp $ |
*/ |
*/ |
#include "ca.h" |
#include "ca.h" |
#include "parse.h" |
#include "parse.h" |
Line 65 void mkpvs(char *fname) |
|
Line 65 void mkpvs(char *fname) |
|
/* function must be declared in advance */ |
/* function must be declared in advance */ |
searchf(CUR_MODULE->usrf_list,fname,&f); |
searchf(CUR_MODULE->usrf_list,fname,&f); |
if ( !f ) { |
if ( !f ) { |
buf = ALLOCA(strlen("undeclared function "+strlen(fname)+10)); |
buf = ALLOCA(strlen("undeclared function ")+strlen(fname)+10); |
sprintf(buf,"undeclared function `%s'",fname); |
sprintf(buf,"undeclared function `%s'",fname); |
yyerror(buf); |
yyerror(buf); |
error("cannot continue to read inputs"); |
error("cannot continue to read inputs"); |
Line 234 unsigned int makepvar(char *str) |
|
Line 234 unsigned int makepvar(char *str) |
|
c = PVGLOBAL((unsigned int)c); |
c = PVGLOBAL((unsigned int)c); |
} else { |
} else { |
/* not declared as static or extern */ |
/* not declared as static or extern */ |
buf = ALLOCA(strlen("undeclared variable"+strlen(str)+10)); |
buf = ALLOCA(strlen("undeclared variable")+strlen(str)+10); |
sprintf(buf,"undeclared variable `%s'",str); |
sprintf(buf,"undeclared variable `%s'",str); |
yyerror(buf); |
yyerror(buf); |
} |
} |
Line 245 unsigned int makepvar(char *str) |
|
Line 245 unsigned int makepvar(char *str) |
|
return c; |
return c; |
|
|
CONFLICTION: |
CONFLICTION: |
buf = ALLOCA(strlen("conflicting declarations for "+strlen(str)+10)); |
buf = ALLOCA(strlen("conflicting declarations for ")+strlen(str)+10); |
sprintf(buf,"conflicting declarations for `%s'",str); |
sprintf(buf,"conflicting declarations for `%s'",str); |
yyerror(buf); |
yyerror(buf); |
|
return 0; |
} |
} |
|
|
extern FUNC parse_targetf; |
extern FUNC parse_targetf; |