Thread overview | |||||
---|---|---|---|---|---|
|
April 15, 2006 Problem with new (nothrow) | ||||
---|---|---|---|---|
| ||||
Digital Mars C++ doesn't compile a program below. ------ foo.cpp ------ #include <new> using namespace std; main() { char* p = new (nothrow) char [100]; delete[] p; return 0; } ------------------ dmc 8.42.n (Dowloaded as Version 8.47) ------------------------------------------------- $ dmc -I. -IC:/dm/stlport/stlport foo.cpp char* p = new (nothrow) char [100]; ^ foo2.cpp(6) : Error: no match for function '?_P(unsigned ,const std::nothrow_t)' --- errorlevel 1 ------------------------------------------------- -- Alex Vinokur email: alex DOT vinokur AT gmail DOT com http://mathforum.org/library/view/10978.html http://sourceforge.net/users/alexvn |
April 15, 2006 Re: Problem with new (nothrow) | ||||
---|---|---|---|---|
| ||||
Posted in reply to Alex Vinokur | "Alex Vinokur" <alexvn@connect.to> wrote in message news:e1qnjm$1vec$1@digitaldaemon.com... [snip] > ------------------------------------------------- > $ dmc -I. -IC:/dm/stlport/stlport foo.cpp > char* p = new (nothrow) char [100]; > ............................................................................................... ^ > foo2.cpp(6) : Error: no match for function '?_P(unsigned ,const std::nothrow_t)' Of course: foo.cpp(6) : Error: no match for function '?_P(unsigned ,const std::nothrow_t)' ............................................................................................... > > --- errorlevel 1 > ------------------------------------------------- -- Alex Vinokur email: alex DOT vinokur AT gmail DOT com http://mathforum.org/library/view/10978.html http://sourceforge.net/users/alexvn |
October 12, 2008 Re: Problem with new (nothrow) | ||||
---|---|---|---|---|
| ||||
Posted in reply to Alex Vinokur | mingw 3.4.2 compiler does |
Copyright © 1999-2021 by the D Language Foundation