Operating System - Linux
1753597 Members
6567 Online
108796 Solutions
New Discussion юеВ

Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

 
SOLVED
Go to solution
Neel2
Regular Advisor

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi Dennis,

I put the explicit specialization forwards in fund.cxx, and the file got compile succesfully with aCC6, Now i will search the exact location in pclass.h or any other to put these forwards.

Thank you very much for your help.

Best regards,
Neel
Dennis Handly
Acclaimed Contributor

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

>Now i will search the exact location in pclass.h or any other to put these forwards.

If it compiles, you pretty much got the right place.
I found I could move PClassObject::pco_State right after the class PObject but not much farther.

Neel2
Regular Advisor

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi Dennis,

I tried to put forwards in pclass.h file right after the class declaration, and things got compiled, after going ahead with compilation, i got the following errors:

//***************************************//
"vset1.cxx", line 11478: error #3449: explicit specialization of member
"PClassObject::pco_State [with X=VESet>]" must
precede its first use (at line 47 of
"/vobs/cxx/h.cih/cxxcls/template/pclass.h")
PClassObject< VESet< Link< PObject> > >::pco_State = {



then i try to declare VESet in forwards but it doesn't work.

Any pointers would be helpfull.

Best regards,
Neel
Dennis Handly
Acclaimed Contributor

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

>I got the following errors:
"vset1.cxx", line 11478: error #3449: explicit specialization of member
"PClassObject::pco_State" must precede its first use (at line 47 of pclass.h)
PClassObject > >::pco_State

>then I try to declare VESet in forwards but it doesn't work.
>Any pointers would be helpful.

I'm going to have to have another .i file. You probably need to put the forward right after the VESet definition.

Neel2
Regular Advisor

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi Dennis,

I tried after VESet, as suggested by you. Also tried to put VESet forward dec. in pclass.h, but could not help.

Attached is the .i file for your kind reference.

Please suggest.

Best regards,
Neel
Dennis Handly
Acclaimed Contributor

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

You have a problem with your layout. You have the PClassObject template class in pclass.h.

Then your explicitly specialize it in your .C files.

Ideally you should include pclass.h from your .C then add your explicit specialization forwards in the .C. Then include more .h files then finally your explicit specializations in the .C.

It turns out if you just use PClassObject, you can just put them all after PClassObject. But if you have nested templates, you need to put them after the outer level is defined.

Unfortunately that maybe too late since you have:
template
class outer {
...
};

Insert here??
// Then immediate use of outer and PClassObject.

Perhaps it isn't as difficult as I made it?
In your source you have:
#line 10947 "vset1.cxx"
...
// Add it here!
template <>
PClass PClassObject > >::pco_State;

// First "use" of VESet >
template<>
inline VESet< Link< PObject> > ::VESet(_V_ACT *)
: VCollection((_V_ACT *)0)
, members((_V_ACT *)0)
, table((_V_ACT *)0)
, links((_V_ACT *)0)
{}



Neel2
Regular Advisor

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

i Dennis,

Thanks for your investigation. I am happy to say that forward dec. is working.

My curiosity, what type of significance changes has been done with new aCC compiler, to handle this kind of layout? why I need to change my template declaration in source code order to build with new one, since i was working with the old one w/o changes?

Appreciate your answer and would be great helpfull for me to understand that what kind of recent changes done for handling templates in new compiler desing?

Best regards,
Neel
Dennis Handly
Acclaimed Contributor

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

>what type of significance changes has been done with new aCC compiler, to handle this kind of layout? why I need to change my template declaration in source code order to build with new one, since i was working with the old one w/o changes?

Because aCC6 is based on EDG, which is perfect. :-)
It meets the strict interpretation of the Standard in regards to point of instantiation, etc.

>recent changes done for handling templates in new compiler design?

Recent when? From aCC3/aCC5 to aCC6? Or versions of aCC6?

Neel2
Regular Advisor

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined


Nice joke ;-)

>> It meets the strict interpretation of the Standard in regards to point of instantiation, etc.

Could you please provide me some more information, Also do we have some flag/s which will take of the above strict interpretation etc. OR Can you please send me some links which describes the above scenario.

>>Recent when? From aCC3/aCC5 to aCC6? Or versions of aCC6?

from aCC3.57 ??

Best regards,
Neel
Dennis Handly
Acclaimed Contributor

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

>Could you please provide me some more information, Also do we have some flag/s which will take of the above strict interpretation etc. OR Can you please send me some links which describes the above scenario.

Well, there is the C++ Standard.
aCC6 is already non-strict by default.
Here is the aCC5 to aCC6 porting link:
http://h21007.www2.hp.com/portal/site/dspp/menuitem.863c3e4cbcdc3f3515b49c108973a801/?ciid=2708d7c682f02110d7c682f02110275d6e10RCRD

Error 3449 isn't listed because aCC5 was also suppose to flag that as an error.