|
|||||
Referents: silent | |||||
Prerequisite Concepts | Related Syntax |
Usually, in OmniMark, when a referent is written to a referents-allowed
stream, its existence is also noted on the referents
shelf. This means that, whether or not a value is assigned to the referent, its existence can be detected using repeat over referents
(and whether or not it has a value detected using is attached
).
For those cases in which detecting undefined referents is not required, OmniMark allows referents to be written without their existence being noted on the referents
shelf. Instead of outputting a referent to a referents-allowed
stream, a silent-referent
could be output to that stream, as in:
output silent-referent "table mark %d(table-mark-count)"
A silent-referent
, when resolved, takes on its effective value, if any. If the stream to which the silent-referent
was written has no applicable defaulting
value, then it is an error to attempt to resolve the value of the silent-referent
, just as it is an error to attempt to resolve the value of an unattached referent when there is no applicable defaulting
value.
The main advantage of using silent-referent
is apparent when a large number of "marked points" must be placed in the output which indicate where later-determined text may or may not need to be placed. In this case the applicable defaulting
value should be set to a zero-length string so that only the marked points which require replacement text are modified in any way.
Note that if a referent is given a value, then its existence is noted on the referents
shelf whether or not it has been used as a referent
or silent-referent
. Similarly, a referent can be used as both a referent
and a silent-referent
, in which case its use as a referent
will note its existence on the referents
shelf.
Prerequisite Concepts Referents |
Related Syntax silent-referent |
---- |