Re: unresolved symbol & __nw__....



tim.wojtaszek@xxxxxxxxx wrote:
: I have ran into a problem recently with a C++ idiom for keeping classes
: off the heap.

This won't work for aC+ for PA.

: private:
: void* operator new(size_t size);
: void operator delete(void* p){}

You must define these operators. I.e. make them call abort.

: /usr/lib/dld.sl: Unresolved symbol: __nw__5DoStuffClassSFUl (code)
: this __nw__5DoStuffClassSFUI is operator new(), but we are not making
: that call. It appears the compiler is making this call in various

All aC++ constructors have 3 entry points, one does allocation and that
calls operator new.

This has been solved for aCC6 on IPF.

: I'm working on trying to get a simplified case to post, but so far the
: only way i can even get a reference to __nw__DoS.. is to explicitly
: call the operator new().
: tim

You get the reference by calling the constructor when it isn't inlined.

You may want to consider subscribing to CXX-DEV for aC++ questions:
http://h21007.www2.hp.com/dspp/comm/comm_Community_Home_IDX/1,1273,,00.html
.



Relevant Pages

  • Re: Types of constructors
    ... Private mUID As String ... Private Sub New ... the function had full access to the new object's private member fields. ... : What are the other kinds of constructors besides: ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Problem with Eclipse and Enums
    ... >public enum Days ... must they always be private?). ... Eclipse didn't seem to care that the constructors were ...
    (comp.lang.java.help)
  • Re: Rationale for C++/CLI Value Types not having a default constructor
    ... C# doesn't support default constructors for value types either. ... The CLR itself doesn't support default and copy constructors for value types. ... Only those internal types can't be used from any other module, they're private, just like the x86 code generated by a native C++ compiler. ... Anything is doable in private code, but you won't be able to make that public and use that type from other DLLs and other languages. ...
    (microsoft.public.dotnet.languages.vc)
  • Re: Private constructor
    ... I am not asking a about private copy ... If you want to create singletons, you have to declare all your constructors ... Then you create a public function that checks if singleton was created ...
    (comp.lang.cpp)