Anonymous user
Address of a variable: Difference between revisions
→{{header|COBOL}}: syntax highlighting doesn't support freeform 🗿
Deadmarshal (talk | contribs) m (→{{header|Oberon-2}}: Added syntax highlighting) |
imported>Acediast (→{{header|COBOL}}: syntax highlighting doesn't support freeform 🗿) |
||
Line 526:
===Get Address===
<syntaxhighlight lang="cobol">
WORKING-STORAGE SECTION.
01 ptr
01 var
PROCEDURE DIVISION.
===Set Address===
Line 538:
<syntaxhighlight lang="cobol">
OCOBOL*> Rosetta Code set address example
*> tectonics: cobc -x setaddr.cob && ./setaddr
DATA DIVISION.
01 prealloc pic x(8) value 'somedata'.▼
WORKING-STORAGE SECTION.
SET ADDRESS OF var TO ADDRESS OF prealloc
DISPLAY var END-DISPLAY
*> 'somedata'
GOBACK.
END PROGRAM setaddr.
</syntaxhighlight>
=={{header|Commodore BASIC}}==
|