NCurses and Standard Template Library String Containers

I am using Momentics 6.2.1 with the standard libraries. I am linking
against the GNU libraries with exceptions. I am having problems compiling a
bit of code which I am using ncurses <ncurses.h> and std::string .

when i try to do the following:

assume std::string::myString; is declared as a member variable of a class

in a member function of declared class I attempt to do

myString.erase(myString.end()); //erase the last character of the string
using the end iterator.

i get the following error from the compiler error
C:/QNXsdk/workspace/VMEDebug/vmedebug.cpp:1927: arguments given to macro
the headers are included in the following order in the class declaration
#include <hw/inout.h>
#include <ctype.h>
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ncurses.h>
#include <sys/mman.h>
#include “vapi.h”
#include “stdtypes.h”