🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Peter Flass Sun, 29 Nov 2026 18:00
Re: Named constant values in Multics PL/I
#33
Author: Peter Flass
Date: Sun, 29 Nov 2026 18:00
36 lines
2778 bytes
[alt.os.multics is fairly inactive]

On 11/28/26 19:08, David Meyer wrote:
 > IBM and Kednos PL/I compilers support the naming of problem/
 > computational data value constants with the %declare and %replace
 > preprocessor statements, respectively.
 >
 > However, I can't find anything like this in the Honeywell Multics PL/I
 > manuals on bitsavers.org. Am I missing something, or does Multics PL/I
 > have no way to indicate a constant data value other than with a literal?
 >

DCL x FIXED BIN INIT(n) STATIC OPTIONS(CONSTANT);

The <options attribute> may specify the parenthesized keyword "constant" 
for items that are not entry values.
Specification of "constant" causes the variable to be allocated in the 
text section of the object segment.
The completed <attribute set> of a variable for which 
"options(constant)" has been
specified must contain the <internal attribute>, the <static attribute>, 
and either the <initial attribute> or the <structure attribute>. If the 
latter is true, all nonstructure members of the structure must contain 
the <initial attribute>.
Except for its allocation, the variable is treated semantically as
any other internal static variable. It is an error to change the value 
of a variable for which "options(constant)" has been specified during 
execution of a program.

This is what Iron Spring PL/I does for items declared with the "VALUE" 
attribute instead of "INITIAL".  I'll have to add "OPTIONS(CONSTANT)". 
It doesn't have the same effect as %REPLACE or preprocessor %DECLARE, 
which do a simple text replacement.

Multics does have a PL/I preprocessor "pmac" which has %REPLACE and 
%SET, among other things.
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads