busclose symbol

advertisement
AB34 p 41
AB34.4. I s SUGGESTIONS REGARDING CERTAIN REPRESENTATIONS IN ALGOL 68 W. Freeman
1.
(University of York). Notions bet~reen sub and bus symbols The description of the language could be macle more consistent if NOTiCTs enclosed within sub- and bus-symbols were treated in a similar waywith NOTIONs enclosed within open- and close-symbols and within begin- and end-symbols. The suggestion is as follows: Metaproduction rule: 1.2.5.J)
BRACKET : bracket ; packet ; pack. Production rules: 3.0.1 .J)
NOTlON bracket : sub symbol, NOTION, bus symbol. 3.0-I-k)
NOTION packet : opensub symbol, NOTION, busclose symbol. 3.0.6-a)*
syntactic token : include opensuB symbol ; busclose symbol ; ~.1.1 .e)
opensub symbol
(/ busclose symbol
/) 7.1.1.o)
VICTAL ROWS structured with FIELDS declara%or : VICTAL ROWS rower BRACKET, VICTAL struct~ured with FIELDS declaxo~. 7.1.1.p)
VICTAL ROWS NONSTOWED declarator : VICTAL ROWS rower BRACKET, virtual NONSTOWED declaror. 8.6.1.1 .a) REFETY ROWSETY ROWWSETY NONROW slice : weak REFETY ROWS ROWWSETY NONR0~ primary, ROWS l e a v ~
Extensions (to be deleted): 9.C) delete line ~ for an open-symbol, and delete line V for a close-symbol. Delete section 9.2.g.
ROWSETY indexer BRAC~T. ABe4 p 42 2.
Confusion between certain onerators It is easy to confuse the operator representations ctb and ctg~.
~ue operator crab is inconsistent with modb and overb since the "and becozes" is represented by "ab" rather than just "b".
To a learner of the l~us-aa/e, the analogy with modb and overb is ct.bwhich he is very likely ~o write for "conforms to and becomes". ~Z suggestion is that c t b b e restored to its former (~95) function az "conforms to and becomes" and that some other symbol be used for "cha~s to bytes".
For this purpose I suggest EITHER that both conversions "chars to bytes" and "bools to bits" be defined as the same operator with representation pack (since the bytes or bits are to be packed into words), OR that "chars to bytes" be represented byctob, and "bools to bits" be represented by b$ob. In either case, I would further suggest that the proposed "int to sez~" operator representation its (see AB 52,3.4, p46) be ires I or, more mnemonically, level. ~,
Differs-from and is-n,ot symbols Nany types of data preparation equipment do not have the ~ character, m~d their users must therefore resort to the representations n e (or 'NE') and is not (or %snt or 'iS NOT' or 'ISNT') for the differs-from symbol and is- not symbol respectively.
These are somewhat cumbersome. Since the representationsof the is-at-most symbol and is-at-least symbol include <= and >= respectively, I would suggest that < > be included ~_uong the representations of the differs-from symbol and that :<>: be included azong the representations of the is-not symbol.
differs from symbol
~
<>
n_.e
is at most symbol
~
<=
I.~ is at least symbol
~
>=
equals symbol
= is symbol
.=-:
i_~ is not symbol
:~:
:<>: isnt
One would then have: -n = -~ ~s not AB34 p 43
4-
Over ~nd modulo, operators These suggestions belong together logically and are intended to alleviate three difficulties: I) The character $ is not commonly available on data preparation equipment. 2) The compound ~: is not a mnemonic rep~esentatlon (at least to the ~riter) for the modulo symbol. 3) The compound $::= appears (at least to %he writer) to divide more easily into v} followed by ::- than into the correct ~: and := and this is liable to mislead the learner of the language. ~
suggestions are as follows: The character % should be included among the representations of the over symbol since it is commonly available and is graphically s~m~lar to ÷. Similarly, %:= should be included among the representations of the over- and-becomes symbol. together withmod should be the repre- The compound%~ and the compound ~
This is fairly mnemonic since A ~od 3 is sentations of the modulo symbol.
given by A - A % B * B, at least in the number-theoretic definition. The compound%*:= and the compoundS*:- together with modb should be the representations of the modulo-and-becomes symbol. One would then have: over and becomes symbol
~:.
%:.
overb
modulo and becomes symbol
~-*:-
%*:-
modb
over symbol
~
%
over
modulo symbol
÷*
%*
~oa
AB]4 p 44
5-
Doom zynbo! Since ** is a representation of the up symbol, ~nd since it is propozed (see AB 32.3.4, p46) that the use of / as a monadic operator b~ forbidden, I suggest that // be included among the representations of the do~n s~ubol. 6.
Vertical line Since the vertical line I is so useful for abbreviating then, in, else, out, thef and elsf symbols, and since it is not commonly available on data pzep- t aration equipment, I would suggest that the exclamation mark : ~T~ich is zore commonly available be an alternative representation.
This would require that : be no longer a representation of the plus-l-tlmes symbol and so i would suggest the question mark ? in that role. 
Download