I have a class called Point.
Point.h :
#ifndef POINT_H
#define POINT_H
#include "Vector.h"
#include <iostream>
class Point
{
friend ostream& operator<<(ostream& output, const Point& p) //must have global scope
{
output << "x: " << x << " y: " << y;
return output;
}
The compiler is telling me
syntax error: Missing ';' before '&'
Am I doing something wrong?
Thanks!
Dave