"any.h": E2293 ) expected at line 210 ... why?

J

j. smith

Hi,

I need your help!
Why does Borland Builder says

E2293 ) expected at line 210

when using the fellowing line:

virtual void Parse(const TCHAR* szValue) = 0;


You guys any idea?

Thanks in advance.

--kryble
 
R

Ron Natalie

j. smith said:
Hi,

I need your help!
Why does Borland Builder says

E2293 ) expected at line 210

when using the fellowing line:

virtual void Parse(const TCHAR* szValue) = 0;

Is TCHAR defined?
Hopefully this is a member function definition.
 
H

Howard

Is that line 210?
Is TCHAR defined?
Hopefully this is a member function definition.

Are there any other errors, especially related to an include file? Previous
errors (and sometimes warnings) can sometimes make something look like an
error that is not, because the parser gets confused.

-Howard
 
G

Greg Schmidt

I need your help!
Why does Borland Builder says

E2293 ) expected at line 210

when using the fellowing line:

virtual void Parse(const TCHAR* szValue) = 0;

Does line 209 look anything like

int GetProperty() const { return m_property; // note lack of trailing }

As Howard indicated, it's almost certainly an error somewhere before
this line, and the parser doesn't realize it until here.
 
J

j. smith

Hi,

thank you very much for your pleasant help!
Does line 209 look anything like

int GetProperty() const { return m_property; // note lack of trailing }

207: virtual bool ToBool() const = 0; // like XPATH function boolean()
208:
209: virtual void Empty() { m_bIsEmpty = true; }
210: virtual void Parse(const TCHAR* szValue) = 0;
211: virtual CSchemaType& Assign(const CSchemaType& rOther) = 0;
212:
213: bool IsEmpty() const { return m_bIsEmpty; }

These lines are part of generated code from Altova XMLSpy.
When I use G++ as compiler no errors occur. In this case it's Borland C++ Builder 6.

So what am I doin wrong?

Thanks again!

--kryble
 
G

Greg Schmidt

Curse my choice of non-programmer friendly font in my newsreader! I
read your original post as having the compiler complain about a missing
close brace, not a missing close parenthesis.
207: virtual bool ToBool() const = 0; // like XPATH function boolean()
208:
209: virtual void Empty() { m_bIsEmpty = true; }
210: virtual void Parse(const TCHAR* szValue) = 0;
211: virtual CSchemaType& Assign(const CSchemaType& rOther) = 0;
212:
213: bool IsEmpty() const { return m_bIsEmpty; }

Everything there looks fine to me.
These lines are part of generated code from Altova XMLSpy.
When I use G++ as compiler no errors occur. In this case it's Borland C++ Builder 6.

Now that is strange. A missing bracket of any kind will always be a
syntax error. If g++ handles it okay, then the code must be valid. So,
it points to some environmental difference (such as include files).

Do both compilers use the same include files (by which I mean when you
say #include <string> do both of them find <string> in the same place)?
If so, you may be able to convince the compilers to give you a list of
include files as they are used (I know MSVC++ has this option, I assume
other compilers will too) and compare the outputs for hints.

Otherwise, I guess you may be stuck with commenting out parts of the
code until the error goes away, and using that as a hint that will
hopefully point towards where the actual problem is.
 
J

j. smith

Hi,

thanks for your help!

Ron Natalie said:
Is TCHAR defined?

It obviously has something to do with the TCHAR thing. Lots of
error-msgs follows which focus on the same problem.
As I said in a later post this code-snippet is part of Altova XMLSpy
2004 Ent. generated C++ code based upon XercesC. When using G++ as a
compiler (instead of bcc32 in this case) everything seems to work
fine.
I just have the MSVC++ project file but I use CBuilderX as IDE.

Anyone knows a solution?

Thanks again.

--kryble
 
R

Ron Natalie

j. smith said:
It obviously has something to do with the TCHAR thing. Lots of
error-msgs follows which focus on the same problem.
As I said in a later post this code-snippet is part of Altova XMLSpy
2004 Ent. generated C++ code based upon XercesC. When using G++ as a
compiler (instead of bcc32 in this case) everything seems to work
fine.
I just have the MSVC++ project file but I use CBuilderX as IDE.
TCHAR is a goofy variable in the Microsoft-specific runtimes.
It is either "char" or "wchar_t" based on whether the UNICODE
(or is it _UNICODE) is defined.

Go to MSDN.MICROSOFT.COM and type tchar or Unicode into
the search engine for more info.
 
Joined
Oct 27, 2008
Messages
1
Reaction score
0
Check your header includes. I had this error when I used "#include <map>" but when I changed it to "#include <map.h>" the error was resolved.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,432
Messages
2,571,682
Members
48,796
Latest member
Greg L.

Latest Threads

Top