View previous topic :: View next topic
|
Author |
Message |
Pavankumar.m Warnings : 1 New User
Joined: 28 Nov 2010 Posts: 53 Location: Mumbai
|
|
|
|
Hi ,
Can any one please tell me how to declare comp-5 field in assembly language.
Ex :below cobol field i want to declare it in assembly language.
cobol:-
10 ABC PIC 9(4) COMP-5.
Assembly:- ?
Thanks and Regards,
pavan Kumar.M |
|
Back to top |
|
|
Bill O'Boyle
CICS Moderator
Joined: 14 Jan 2008 Posts: 2501 Location: Atlanta, Georgia, USA
|
|
|
|
If it's aligned - PIC 9(04) COMP-5 SYNC -
If it's unaligned - PIC 9(04) COMP-5 -
O R -
In your example, choose unaligned (either one). |
|
Back to top |
|
|
Pavankumar.m Warnings : 1 New User
Joined: 28 Nov 2010 Posts: 53 Location: Mumbai
|
|
|
|
Thank you so much bill :-) |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
In COBOL, all fields which are defined as "binary" are defined identically in storage.
That is,usage COMP-5 is defined in exactly the same way as BINARY/COMP/COMP-5.
What is different in COBOL about those fields is the code that is generated to use them.
Assembler doesn't generate code for you.
If you want a field in Assembler to behave as if it were a COMP-5 in COBOL, then you're going to have to produce equivalent code, not equivalent definitions. |
|
Back to top |
|
|
|