[TUHS] v7 K&R C

Paul Winalski paul.winalski at gmail.com
Fri May 15 03:08:20 AEST 2020


On 5/13/20, Paul McJones <paul at mcjones.org> wrote:
>
> C continues the tradition begun by Fortran and Algol 60 of overloading the
> arithmetic operators on the various numeric types. C++ allows new types to
> be defined; when a new type obeys the generally understood properties of a
> built-in type, it makes sense to use the same operator (or function) for the
> corresponding operation on the new type (e.g., addition on complex numbers,
> arbitrary-precision integers and rationals, polynomials, or matrices).

I agree; that makes sense.  But I don't like things such as << and >>
in I/O-related classes.

-Paul W.


More information about the TUHS mailing list