Visual C++ 7.1 Internal Compiler Error

  • Thread starter Gabriel Becedillas
  • Start date
G

Gabriel Becedillas

During the last weeks I've trying to port boost::python 1.23 to work
with Visual C++ 7.1. I had some headaches while doing so because VC++
7.1 supports Koenig lookup and previous ones doesn't support it (and
aparently boost::python 1.23 was not written with Koenig support in
mind).
While doing so I faced an ICF.. which I can reproduce with the code
that follows. Does anybode know if this is fixed somehow ?.
I'm not sure if the call to some_friend inside
bang_bang_icf_shot_me_down is ok or not.. and thats not what I want to
find out right now. The ICF I'm getting is inside a piece of code that
is so much bigger. This is just a simplified example of what I think
is trigering the ICF.
Thanks.

namespace pindonguita
{
struct lookup_helper
{};

class A
{
public:
friend void some_friend(lookup_helper)
{}
};

template <typename T>
void bang_bang_icf_shot_me_down(lookup_helper a_T)
{::some_friend(pindonguita::lookup_helper());}
}

int main()
{
pindonguita::A int_conv;
some_friend(pindonguita::lookup_helper());
pindonguita::bang_bang_icf_shot_me_down<int>(pindonguita::lookup_helper());
return 0;
}
 
R

Rob Williscroft

Gabriel Becedillas wrote in
in comp.lang.c++:
During the last weeks I've trying to port boost::python 1.23 to work
with Visual C++ 7.1. I had some headaches while doing so because VC++
7.1 supports Koenig lookup and previous ones doesn't support it (and
aparently boost::python 1.23 was not written with Koenig support in
mind).

The term "Koenig lookup" nolonger appears in the (revised) standard.
I prefere ADL (Argument Dependant Lookup) - it does what it says on
the tin.

While doing so I faced an ICF.. which I can reproduce with the code
that follows. Does anybode know if this is fixed somehow ?.

You should ask in <most
of the beta testers for the next version of VC++ hangout there and
maybe will put you code though the latest version to see if its
fixed.
I'm not sure if the call to some_friend inside
bang_bang_icf_shot_me_down is ok or not..

No you try to call ::some_friend(), the scope resolution operator
disables ADL and there is no function ::some_friend(). You should be
getting an error telling you that however, not an ICF (Note ICE as
in Internal Compiler Error, is the usual abbreviation for this).
and thats not what I want to
find out right now. The ICF I'm getting is inside a piece of code that
is so much bigger. This is just a simplified example of what I think
is trigering the ICF.
namespace pindonguita
{
struct lookup_helper
template <typename T>
void bang_bang_icf_shot_me_down(lookup_helper a_T)
{::some_friend(pindonguita::lookup_helper());}
}

You might want to post this on the Boost.Python sig

news://news.gmane.org/gmane.comp.python.c++

Its mentioned here.

http://www.boost.org/more/mailing_lists.htm

HTH.

Rob.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,066
Latest member
VytoKetoReviews

Latest Threads

Top