c++ - NEW Problems...
- DigitalMars (26/26) Jun 12 2002 I've purchased the CD and am working through the Sams 24 hour book to
- Laurentiu Pancescu (11/36) Jun 14 2002 It looks to me there's an extra comma in the error message - isn't it:
- DigitalMars (10/60) Jun 14 2002 Yeh, Walter sent me an email...so I'm not the brightest crayon in the
- Jan Knepper (6/73) Jun 14 2002 sc.ini
- Laurentiu Pancescu (11/15) Jun 14 2002 C'mon, you're being too harsh with yourself! Every compiler has its own
I've purchased the CD and am working through the Sams 24 hour book to refresh my memory on how to code in a real language. Got to the point where the examples require an array: CArray<CString, CString> m_arNames; added: #include <afxtempl.h> to afx.h so I go to compile and get the following: sc dvtesdoc.cpp -cpp -Ae -mn -C -WA -S -3 -a8 -c -H -HO- -gf -D_DEBUG=1 -D_X86_ =1 -D_MT=1 -odvtesdoc.obj Error: C:\DM\BIN\..\mfc\include\32-bit\afxtempl.h(305): no match for function '?_P(unsigned ,char *,int )' Lines Processed: 225 Errors: 1 Warnings: 0 Build failed The line that is gagging is: m_pData = (TYPE*) new BYTE[nNewSize * sizeof(TYPE)]; I ran into this when trying to comple some of the MFC samples from the web site...gave up and bought the CD...I never tried the MFC samples of the disc. I realize that I'm probably missing something incredibly obvious...but it's been almost 5 years since I last wrote a line of c/c++ and I seem to have killed of the brain cells that held those 15 years of experience.... Thanks ... Michael mcmprch adelphia.net mcmprch soundbeachfinancial.com
Jun 12 2002
It looks to me there's an extra comma in the error message - isn't it: function '?_P(unsigned char *,int )' ? If so, check the command line parameters, you mught need to enable support for operators new[] and delete[] - check compiler manual... HTH, Laurentiu "DigitalMars" <mcmprch soundbeachfinancial.com> wrote in message news:ae7l14$14tk$1 digitaldaemon.com...I've purchased the CD and am working through the Sams 24 hour book to refresh my memory on how to code in a real language. Got to the pointwherethe examples require an array: CArray<CString, CString> m_arNames; added: #include <afxtempl.h> to afx.h so I go to compile and get the following: scdvtesdoc.cpp -cpp -Ae -mn -C -WA -S -3 -a8 -c -H -HO- -gf -D_DEBUG=1 -D_X86_=1 -D_MT=1 -odvtesdoc.obj Error: C:\DM\BIN\..\mfc\include\32-bit\afxtempl.h(305): no match for function '?_P(unsigned ,char *,int )' Lines Processed: 225 Errors: 1 Warnings: 0 Build failed The line that is gagging is: m_pData = (TYPE*) new BYTE[nNewSize * sizeof(TYPE)]; I ran into this when trying to comple some of the MFC samples from the web site...gave up and bought the CD...I never tried the MFC samples of the disc. I realize that I'm probably missing something incredibly obvious...butit'sbeen almost 5 years since I last wrote a line of c/c++ and I seem to have killed of the brain cells that held those 15 years of experience.... Thanks ... Michael mcmprch adelphia.net mcmprch soundbeachfinancial.com
Jun 14 2002
Yeh, Walter sent me an email...so I'm not the brightest crayon in the Box...RTFM... BTW, how can I force the IDDE to generate -Aa- in the makefile...I keep changing the makefile and the silly IDDE keeps changing it back?.... Michael "Laurentiu Pancescu" <user nowhere.near> wrote in message news:aecg94$2ikc$1 digitaldaemon.com...It looks to me there's an extra comma in the error message - isn't it: function '?_P(unsigned char *,int )' ? If so, check the command line parameters, you mught need to enable support for operators new[] and delete[] - check compiler manual... HTH, Laurentiu "DigitalMars" <mcmprch soundbeachfinancial.com> wrote in message news:ae7l14$14tk$1 digitaldaemon.com...dvtesdoc.cpp -cpp -Ae -mn -C -WA -S -3 -a8 -c -H -HO- -gf -D_DEBUG=1 -D_X86_I've purchased the CD and am working through the Sams 24 hour book to refresh my memory on how to code in a real language. Got to the pointwherethe examples require an array: CArray<CString, CString> m_arNames; added: #include <afxtempl.h> to afx.h so I go to compile and get the following: scweb=1 -D_MT=1 -odvtesdoc.obj Error: C:\DM\BIN\..\mfc\include\32-bit\afxtempl.h(305): no match for function '?_P(unsigned ,char *,int )' Lines Processed: 225 Errors: 1 Warnings: 0 Build failed The line that is gagging is: m_pData = (TYPE*) new BYTE[nNewSize * sizeof(TYPE)]; I ran into this when trying to comple some of the MFC samples from thehavesite...gave up and bought the CD...I never tried the MFC samples of the disc. I realize that I'm probably missing something incredibly obvious...butit'sbeen almost 5 years since I last wrote a line of c/c++ and I seem tokilled of the brain cells that held those 15 years of experience.... Thanks ... Michael mcmprch adelphia.net mcmprch soundbeachfinancial.com
Jun 14 2002
sc.ini OR in de 'defines' edit field in the IDDE: change your defines from "X;Y;Z" to "-DX -DY -DZ -Aa-" Jan DigitalMars wrote:Yeh, Walter sent me an email...so I'm not the brightest crayon in the Box...RTFM... BTW, how can I force the IDDE to generate -Aa- in the makefile...I keep changing the makefile and the silly IDDE keeps changing it back?.... Michael "Laurentiu Pancescu" <user nowhere.near> wrote in message news:aecg94$2ikc$1 digitaldaemon.com...It looks to me there's an extra comma in the error message - isn't it: function '?_P(unsigned char *,int )' ? If so, check the command line parameters, you mught need to enable support for operators new[] and delete[] - check compiler manual... HTH, Laurentiu "DigitalMars" <mcmprch soundbeachfinancial.com> wrote in message news:ae7l14$14tk$1 digitaldaemon.com...dvtesdoc.cpp -cpp -Ae -mn -C -WA -S -3 -a8 -c -H -HO- -gf -D_DEBUG=1 -D_X86_I've purchased the CD and am working through the Sams 24 hour book to refresh my memory on how to code in a real language. Got to the pointwherethe examples require an array: CArray<CString, CString> m_arNames; added: #include <afxtempl.h> to afx.h so I go to compile and get the following: scweb=1 -D_MT=1 -odvtesdoc.obj Error: C:\DM\BIN\..\mfc\include\32-bit\afxtempl.h(305): no match for function '?_P(unsigned ,char *,int )' Lines Processed: 225 Errors: 1 Warnings: 0 Build failed The line that is gagging is: m_pData = (TYPE*) new BYTE[nNewSize * sizeof(TYPE)]; I ran into this when trying to comple some of the MFC samples from thehavesite...gave up and bought the CD...I never tried the MFC samples of the disc. I realize that I'm probably missing something incredibly obvious...butit'sbeen almost 5 years since I last wrote a line of c/c++ and I seem tokilled of the brain cells that held those 15 years of experience.... Thanks ... Michael mcmprch adelphia.net mcmprch soundbeachfinancial.com
Jun 14 2002
"DigitalMars" <mcmprch soundbeachfinancial.com> wrote in message news:aecnhk$2pmo$1 digitaldaemon.com...Yeh, Walter sent me an email...so I'm not the brightest crayon in the Box...RTFM...C'mon, you're being too harsh with yourself! Every compiler has its own command-line switches, and verifying all switches is a pain... I knew about this since DMC had different defaults some time ago (I'm using it since before the first CD appeared, and Walter was so kind to send me an alpha CD - thanks again for this, Walter!!!), and got this problem too - not with MFC, but some simple code of my own.BTW, how can I force the IDDE to generate -Aa- in the makefile...I keep changing the makefile and the silly IDDE keeps changing it back?....I think sc.ini is the best way, as Jan already suggested. Regards, Laurentiu
Jun 14 2002