-   Programming (
-   -   g++ caused a SEGV! Sweet! (

The_Nerd 06-23-2004 01:44 PM

g++ caused a SEGV! Sweet!
Check this out:
(writing this from memory... so it my be incomplete)


template <class T>
myotherclass<T> *myclass<T>::operator[](int i)
    myotherclass<T> *Temp=this->Val[i];
    return (Temp==NULL)?this->Val.pData:Temp->pData;

This code (it was VERY similar if not this) caused g++ to segmentation fualt! HAha!

I bet you guys never coded so poorly that gcc caused a SEGV! SWEET!

:D :cool:

Thats what happens when you are learning I guess. :newbie:

infamous41md 06-23-2004 02:06 PM

you should reproduce it exactly and contact g++ developers.

The_Nerd 06-23-2004 06:39 PM

I was going too, but then I though that I didn't have the newest version of gcc, and that I didn't really want to install an update at this time. Anyhow, I probably will sometime.

All times are GMT -5. The time now is 10:44 PM.