[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
classical error but unresolved "syntax error at end of input"
From: |
soledady |
Subject: |
classical error but unresolved "syntax error at end of input" |
Date: |
Tue, 09 Aug 2005 17:23:16 +0200 |
the result of the grammar file (*.y) compilation give me this error:
"syntax error at end of input"
I Know this is not really important but i don't find it and I can't test
my grammar file I give you the code (begin and end of it)
A warning appear to indicate that yyerror has been declared on implicit
way "Static" and farrer "extern" I really don't know what is the meaning
and if it's important or not...
thanks for your help
%{
//#include "global.h"
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include "SuiteTest.c"
%}
%token DEBUT FIN
%left PLUS MOINS
%left FOIS DIVISE
%right EXP
%start P
%%
P : DEBUT S FIN {testRecup();}
[...........some grammar rule.......]
[...........]
|NUL SEMI_COLUMN Qb {printf(" ");}
|/*vide*/ {printf(" ");}
%%
int yyerror(char *s) {
printf("%s\n",s);
return 0;
}
int main(void) {
yyparse();
return 0;
}