help-flex
[Top][All Lists]
Advanced

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

Scanninga a string in a c++


From: Leopold Palomo Avellaneda
Subject: Scanninga a string in a c++
Date: Wed, 16 Apr 2003 12:50:17 +0200
User-agent: KMail/1.5.1

Hi,

I know that this is a common question. I have read the archives, the 
documentation, but I'm desesperately trying to understand what happens to my 
lexer.

I'm addapting a lex and yac files to my c++ apps. I know an epsilon about lex 
and yac. I need only to adapt a lex and yac files that worked.

I have followed a n example of this, and I have my program compiling without 
errors. Howeber, I would like to scan an string in my Flexer class, and I 
don't know what to do it.

I have derived my class to have acces to the LexerInput procedure, but it do 
nothing. I have tested to pass a istringstream, and nothing. I have done a 
trace of my program and althouth I think I pass the string, when arrives to 
the FlexerClass base, desaperars, so all the time the program goes to :

case YY_STATE_EOF(INITIAL):
yyterminate();

because has nothing to scan.


Please, could someone help me, or point me what I have to look, or show me and 
example of this.

Regards,

Leo






reply via email to

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