Home     |     .Net Programming    |     cSharp Home    |     Sql Server Home    |     Javascript / Client Side Development     |     Ajax Programming

Ruby on Rails Development     |     Perl Programming     |     C Programming Language     |     C++ Programming     |     IT Jobs

Python Programming Language     |     Laptop Suggestions?    |     TCL Scripting     |     Fortran Programming     |     Scheme Programming Language


 
 
Cervo Technologies
The Right Source to Outsource

MS Dynamics CRM 3.0

C++ Programming

Strange error


struct __alloca
{
        unsigned int    nsize;
        int                             nline;
        char                    szFile[250];
        char                    **messages;
        int                             trace_size ;
#ifdef OS_WINDOWS
        unsigned long     m_size;
        _CRT_ALLOC_HOOK  m_poldhook;
        HMODULE          m_dbghelp;
        HANDLE           m_process;
        HANDLE           m_thread;       // Pseudo-handle meaning "current
thread" - required for obtaining stack traces
    DWORD            m_tlsindex;     // Index for thread-local storage
of VLD data
        STACKFRAME64     m_frame;
#endif

};

typedef map<void*,__alloca> MEMALLOCMAP;
typedef MEMALLOCMAP::iterator ITEM;

I get the error
error C2143: syntax error : missing ';' before '<'
error C2143: syntax error : missing ';' before '<'
error C2653: 'MEMALLOCMAP' : is not a class or namespace name

Please help me out fast
TAI
~Neil

My guess would be that the compiler doesn't find a definition for 'map'.
Another guess would be that you mean the standard type std::map. Did you do
an '#include <map>' and a 'using std::map;'?
On 7 Juni, 13:16, Neil <neilsayshe@gmail.com> wrote:

Since you didn't provide the lines on which the errors occurred I can
only guess, but perhaps you have not included <map> or you need to
prefix map<...> with std::.

--
Erik Wikstrm

MEMALLOCMAP is not a class or namespace name, clear enough. It's a
variable name. The correct typedef syntax is:
typedef typename std::map<void *, __alloca>::iterator ITEM;

it's not a class because of the previous errors.

Regards,

Zeppe

In addition to the other errors pointed out, the name __alloca is not
available for your use.  Identifiers containing a double underscore are
reserved to the implementation.
Add to del.icio.us | Digg this | Stumble it | Powered by Megasolutions Inc