hi ,
 
            I am new to bison. I got a memory leak. Leak is due to the
strdup in lex file
 
astr         [-a-zA-Z0-9_\.\/\,\<]*
 
 
{astr}   {
                yylval.text = strdup( (char *)yytext );
                return ASTR;
        }

            I have added
 
%destructor  { free($$); }   ASTR   
 
            but still i am getting memory leaks(valgrind).
 
can anyone help me how to solve this ???????
 
Thanks & Regards,
Harish Kumar Chaluvadi.
 
_______________________________________________
help-bison@gnu.org http://lists.gnu.org/mailman/listinfo/help-bison

Reply via email to