summaryrefslogtreecommitdiffstats
path: root/gnu/lib/libg++/include/Complex.h
diff options
context:
space:
mode:
authorrgrimes <rgrimes@FreeBSD.org>1995-05-30 05:05:38 +0000
committerrgrimes <rgrimes@FreeBSD.org>1995-05-30 05:05:38 +0000
commit2ad6f3dee6bc54535003f4ab26bbc587b7efa38c (patch)
treea3959baf797787918878bec6d58d6a0fb743ad0a /gnu/lib/libg++/include/Complex.h
parent4f960dd75f181e9fa2edc44324f15f0ab5c64b37 (diff)
downloadFreeBSD-src-2ad6f3dee6bc54535003f4ab26bbc587b7efa38c.zip
FreeBSD-src-2ad6f3dee6bc54535003f4ab26bbc587b7efa38c.tar.gz
Remove trailing whitespace.
Diffstat (limited to 'gnu/lib/libg++/include/Complex.h')
-rw-r--r--gnu/lib/libg++/include/Complex.h46
1 files changed, 23 insertions, 23 deletions
diff --git a/gnu/lib/libg++/include/Complex.h b/gnu/lib/libg++/include/Complex.h
index 9b7e378..128227bc 100644
--- a/gnu/lib/libg++/include/Complex.h
+++ b/gnu/lib/libg++/include/Complex.h
@@ -1,5 +1,5 @@
// This may look like C code, but it is really -*- C++ -*-
-/*
+/*
Copyright (C) 1988 Free Software Foundation
written by Doug Lea (dl@rocky.oswego.edu)
@@ -57,8 +57,8 @@ public:
Complex& operator *= (const Complex& y);
Complex& operator *= (double y);
- Complex& operator /= (const Complex& y);
- Complex& operator /= (double y);
+ Complex& operator /= (const Complex& y);
+ Complex& operator /= (double y);
void error(const char* msg) const;
};
@@ -83,7 +83,7 @@ Complex pow(const Complex& x, int p);
Complex pow(const Complex& x, const Complex& p);
Complex pow(const Complex& x, double y);
Complex sqrt(const Complex& x);
-
+
istream& operator >> (istream& s, Complex& x);
ostream& operator << (ostream& s, const Complex& x);
@@ -99,42 +99,42 @@ inline Complex::Complex(double r, double i) :re(r), im(i) {}
inline Complex::~Complex() {}
-inline Complex& Complex::operator = (const Complex& y)
-{
- re = y.real(); im = y.imag(); return *this;
-}
+inline Complex& Complex::operator = (const Complex& y)
+{
+ re = y.real(); im = y.imag(); return *this;
+}
inline Complex& Complex::operator += (const Complex& y)
-{
- re += y.real(); im += y.imag(); return *this;
+{
+ re += y.real(); im += y.imag(); return *this;
}
inline Complex& Complex::operator += (double y)
-{
- re += y; return *this;
+{
+ re += y; return *this;
}
inline Complex& Complex::operator -= (const Complex& y)
-{
- re -= y.real(); im -= y.imag(); return *this;
+{
+ re -= y.real(); im -= y.imag(); return *this;
}
inline Complex& Complex::operator -= (double y)
-{
- re -= y; return *this;
+{
+ re -= y; return *this;
}
inline Complex& Complex::operator *= (const Complex& y)
-{
+{
double r = re * y.real() - im * y.imag();
- im = re * y.imag() + im * y.real();
- re = r;
- return *this;
+ im = re * y.imag() + im * y.real();
+ re = r;
+ return *this;
}
inline Complex& Complex::operator *= (double y)
-{
- re *= y; im *= y; return *this;
+{
+ re *= y; im *= y; return *this;
}
@@ -202,7 +202,7 @@ inline Complex operator - (double x, const Complex& y)
inline Complex operator * (const Complex& x, const Complex& y)
{
- return Complex(x.real() * y.real() - x.imag() * y.imag(),
+ return Complex(x.real() * y.real() - x.imag() * y.imag(),
x.real() * y.imag() + x.imag() * y.real());
}
OpenPOWER on IntegriCloud