comp.lang.ada
 help / color / mirror / Atom feed
* Signed Numeric conversions
@ 1993-03-02  0:28 Contractor Bert Nelson
  1993-03-02  4:22 ` Michael Feldman
  0 siblings, 1 reply; 2+ messages in thread
From: Contractor Bert Nelson @ 1993-03-02  0:28 UTC (permalink / raw)



I am trying to create a package that will handle the conversion of
Cobol signed numerics  e.g. S999 into integer and Ada integer back
to a Cobol signed numeric, but every minute the package is becoming 
more and more complicated.

For example a Cobol variable with a picture clause of PIC S999 might
have the values 121 or -121 in it and its signed numeric value is
"12A" and "12J" respectively.  These would correspond with postive
121 and -121 in an Ada integer variable.

Cobol Signed Numeric       Ada integer
12A                            121
12J                           -121


Does anyone have suggestions on a simple way of doing 
conversions from Cobol signed numerics to Ada integer and vice versa??

       
Bert Nelson
Hill Air Force Base
nelsonb@oodis01.af.mil



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Signed Numeric conversions
  1993-03-02  0:28 Signed Numeric conversions Contractor Bert Nelson
@ 1993-03-02  4:22 ` Michael Feldman
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Feldman @ 1993-03-02  4:22 UTC (permalink / raw)


In article <2884@oodis01.af.mil> nelsonb@oodis01.af.mil (Contractor Bert Nelson) writes:
>
>I am trying to create a package that will handle the conversion of
>Cobol signed numerics  e.g. S999 into integer and Ada integer back
>to a Cobol signed numeric, but every minute the package is becoming 
>more and more complicated.
>
etc.

Much of what you are trying to do has already been accomplished in a
set of packages collectively called ADAR, developed by (I believe)
Bob Eachus, Dave Emery, and Ben Brosgol. Perhaps Bob or Dave will
respond about the status of this. I have a several-months old
version of it; Ben told me they were still doing cleanups. It
will be distributed as PD software under CAUWG auspices, I think.

Bob, Dave: back to you...

Mike Feldman
------------------------------------------------------------------------
Michael B. Feldman
co-chair, SIGAda Education Committee

Professor, Dept. of Electrical Engineering and Computer Science
School of Engineering and Applied Science
The George Washington University
Washington, DC 20052 USA
(202) 994-5253 (voice)
(202) 994-5296 (fax)
mfeldman@seas.gwu.edu (Internet)

"The most important thing is to be sincere, 
and once you've learned how to fake that, you've got it made." 
-- old show-business adage
------------------------------------------------------------------------



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1993-03-02  4:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1993-03-02  0:28 Signed Numeric conversions Contractor Bert Nelson
1993-03-02  4:22 ` Michael Feldman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox