C and BCD

mzal at pegasus.UUCP mzal at pegasus.UUCP
Fri Nov 16 01:24:20 AEST 1984

If C was intended as a systems programming language, then it only seems
fair that it should be able to access all functions of the system,
including BCD on those machines which support it.  How a variable
declared as BCD should be handled on non-BCD machines is an issue
which could be left to the implementer.  Alternatively, we could
just say that all BCD variables are of type int on non-BCD machines.

I know of no standards saying that just because something is
declared char or int or double that it needs to be stored in some
special way.  IndeedGi in all versions of C which run on a DEC-20
(that I have seen), chars, ints, longs, and doubles are all 36
bit quantaties.

-- Mike^Z   [allegra!, ihnp4!] pegasus!mzal   Zaleski at Rutgers

More information about the Comp.lang.c mailing list