Article ID: 123803
Article Last Modified on 7/5/2005
/* Compile options needed: none
*/
#include <iostream.h>
template <class T> class genvec3d { };
template <class T>
ostream& operator<< (ostream& o, const genvec3d<T>& p)
{
return o;
}
class ray
{
public:
genvec3d<float> origin;
ray(){}
friend int operator<<(ostream& o, ray& r)
/* The following line causes compiler Error */
{ o << origin; return 1; }
/* To work around the problem, change the line above into a comment and
change the following line to an executed line of code. */
/* { o << r.origin; return 1; } */
};
Additional query words: 9.00 2.00
Keywords: kbbug kbfix kbcpponly kbcompiler KB123803