...NoOperation...
Noop removes itself from its containing
Sequence.
In this
capacity, Noop is called the SequenceNoop.
Noop[] is Null.
Pattern[Noop] matches nothing.
Noop[elicit]
...destroys
both the elicitation,
elicit,
and its assignment.
(If elicit is a subcomponent of a Name’s definition, then
the rest of that Name’s
assignment remains intact.)
If "name" is the StringName of a Name,
Noop[name]
...removes every assignment to name, but not its symbol.
Noop["name"]
...removes
every
assignment to name, and its symbol.
If objectPat is a PatternSet, then...
Noop[objectPat]
...removes
everything
matching objectPat.
The Noop-Named-Error form is a programming standard used to systematize error handling.
See the English
definition for "error"
and "nought".
Noop, n.
(noōp rhymes with "oōp" or "loōp"),
...a word derived from No-Operation or No-Op.
1. Computer.
a Literal: "Noop" designates the No-operation; "Noop" removes itself from its containing Sequence. E.G.
{1, Noop, 3} is reckoned as {1, 3}.
b Failed process signal.
3. Intentionally or unintentionally terminated procedure, or sequence.
4. Fail.
-- See NAUGHT.
Noop is often used as a suffix or prefix keyword modifier.
By convention, as a prefix, Noop is the removal of its argument.
As a suffix it designates a sequence ender
(terminator) as: EndCharacter
or End-Of-File.
See Noops in CharacterSet RuleList.
StreamNoop
and NoopStream,
are,
respectively, Noop-suffix
and Noop-prefix
examples.
(0) Noop
...is a form which removes itself from a Sequence. For
example,
Reckon[{1, Noop,
3, Noop,
5}]
evaluates to...
{1, 3, 5}.
See English
definition for "null".
(1)
Noop[]
...is interpreted as the Null
result.
LogicalPatterns
use
the form,
(2) Pattern[Noop]
...to expand the meaning of a PatternSequence
or PatternTypeSequence
to include sequences
with no elements. Pattern[Noop]
is interpreted as the Pattern
matching nothing.
For example, the following matches nothing or the PatternSequence
matching expr.
(3a)
Or[Pattern[Noop],
Pattern[Sequence][expr]]
In the above ElicitationForm,
the presence of Pattern[Noop],
makes this Or[...] into a Pattern which can
either match
something with no elements, or Pattern[Sequence][expr].
The above form is used throughout this Language
Specification, but written as:
(3b) ___[expr]
The StandardASCIIRuleList,
(amongst other rules for transforming Strings into Expressions) assigns
(3a), wherever it comes across (3b).
If elicit is an EliciationForm, then...
(4)
Noop[elicit]
...destroys both the elicitation, elicit,
and
its assignment and returns nothing (Noop)
if successful.
If elicit is a subcomponent of a Name’s definition, then the rest of that Name’s assignment remains intact.
If name is an unprotected Name, then...
(5)
Noop[name]
...removes every assignment to name,
but
not
its symbol, and returns name (confirming the fact that name
elicits nothing).
By
contrast,
(6) Noop["name"]
...removes every assignment to name,
and
its symbol. Noop,
(nothing) is
returned if the removal is successful. Strings
can be used to
represent underlying Names
in removals like (6) because a String
cannot be assigned to a
value by itself. Only
Names and their ElicitationForms
can be
assigned.
More generally, whenever an Expression is evaluated
and returned unchanged, it means that it
is unassigned. Specifically, if object
has no interpretation,
(7) Noop[object]
...returns object.
If nam is a Name,
then the following is a Trap
for nam-errors:
(8)
Trap[Noop[nam[arg1,
arg2,...]],
eval, exec]
This is an example of a NoopNamedError
(mechanism). If, during the evaluation of eval, an
error is
encountered, this error is reported using an ElicitationForm
matching...
(9)
Noop[nam[arg1,
arg2,...]]
...where arg1, arg2,... have
whatever
value suits
the error-message. When (9) is encounted in eval,
the arg1,
arg2,... are substituted into exec for
systematic
error
processing.
If the NoopNamedError in (8) is not encountered in eval, exec is never evaluated, and the Trap returns eval's result.
The Trap
in (8) preempts any removal that might have otherwise occurred by
invoking
"Noop[nam[arg1, arg2,...]]".
These
NoopNamedError constructs
allow
algorithms to be written with error diagnostic branches,
which
nonetheless result in Noop
unless Traps are
specifically set
for these branches.
See also NotComputeError.
If an Expression, like elicit in "Noop[elicit]", has no assignment (interpretation), it returns unchanged. For example,
Slot["name"][7]
...attempts to access the 7th Character in the String, "name", which does not exist. Consequently, the above elicits nothing and returns unchanged. Unassigned invocations return unchanged; they do not return Noop.
StreamObjects
remain in existence until they are destroyed. In the following,
assume nam2
and nam3 refer to StreamObjects,
then...
(10)
{Noop[Stream[2,
nam2]], Noop[Stream[3,
nam3]], Noop[Stream[3, nam3]]}
...will return...
{Noop[Stream[3,
nam3]]}.
In (10), Stream[2,
nam2], and Stream[3,
nam3] are
removed, and replaced by Noop
in sequence,
thereby removing
them from the sequence.
Since Stream[3,
nam3] has been destroyed, the second occurrence of "Noop[Stream[3,
nam3]]" in (10), does not
reference anything. Thus, there is nothing to destroy,
and the unassigned Expession,
"Noop[Stream[3,
nam3]]", is
returned.
error n.
1. Belief in what is untrue, the state of holding such belief, or an instance of it; as, ones error is no sin; to stand in, or be led into, error.
2. A moral offense; violation of duty; a sin. Ps. xix, 12
3. Obs. a Passionate vexation. b a malformation.
4. An act involving a departure from truth or accuracy; a deviation from, or failure to achieve, the right course or standard; a mistake; as, an error in spelling, taste, etc.
5. A wandering; an irregular course. A Latinism.
6. Baseball. A fault of a player of the side in the field, which prolongs the time at bat of the batsman, or prolongs the life of a base runner, or allows a base runner to advance one or more bases when perfect play would have ensured his being put out. Passed balls and wild pitches are not scored as error s.
7. Christian Science. The contradiction of Truth; a belief without understanding;
...that which seemeth to be and is not. Mary Baker Eddy.
8. Law. a A mistake in the proceedings of a court of record in matters of law or of fact.
b The procedure or proceedings for reversal of a judgment by writ of error.
9. Math. The difference between an observed or calculated value, generally of a physical quantity, and the true value; --called also the true error.&nbssp; Since the true value, or question, is in general unknown and unknowable, the error must be reckoned on some hypothesis, as in physics that the sum of the squared residual errors should be a minimum. The accidental error is that part of the error of observation that may be reduced (as near as one will) from the mean by increasing sufficiently the number of similar observations. The constant error is the part not so reducable. It is the average overestimation or underestimation of a series of observations, and may be theoretical, instrumental, or personal. The mean error is the square root of the mean of the squared errors (of a given class of observations). The probable error is a value that any given error will as likely fall under as exceed. Residual errors are the observed values less their arithmetical mean. The law of error is that the square of any (accidental) error varies as the logarithm of its frequency. See PROBABILITY.
10. Mil. In artillery fire, the divergence of a point of impact from the center of impact.
11. Philately. A stamp that by accident differs from the normal variety in some respect, as to color, pater etc.
Syn. --ERROR, MISTAKE, BLUNDER. [Noop] An ERROR is a departure or deviation from that which is right or correct; as, a typographical error; an error of judgment; "Those who, with sincerity and generosity, fight and fall in an evil cause, posterity can only compassionate as victims of a generous but fatal error." (Scott)
MISTAKE implies misconception, misunderstanding, or inadvertence; it expresses less severe judgment than error; as,
"There is a medium between truth and falsehood, and (I believe) the word mistake expresses it exactly."
"I will therefore say that you were mistaken..." (Cowper).
BLUNDER is harsher than mistake or error; it commonly implies ignorance or stupidity, sometimes blameworthiness; as,
"We usually call our blunders mistakes, and our friends style or mistakes blunders." (H.B. Wheatley);
"It is worse than a crime, it is a blunder!" (trans. from Talleyrnd).
Cf. FAULT, BLEMISH.
COMBINATIONS (in senses 1 & 2) are:
error-blasted, error-proof, error-tainted,
error-darkened, error stricken, error-teaching
nought n.
1. a. Nothing; not a whit; naught.
b. A state or result that amounts to nothing.
2. Nonexistence; nonentity; nothingness. Archaic.
3. Wickedness; wrong; hence, that which is wrong. Obs.
4. A worthless or valueless thing or person; a nothing.
5. = naught.
null adj
1. Of no legal or binding force or validity; of no efficacy; invalid; void; nugatory.
2. Amounting to nothing or nil; nonexistent.
3. Of no consequence or value; insignificant.
4. Math or Symbolic Logic. Empty or having no members; as, the null class; having the character or value of 0; as, the null element; having a zero radius; as, a null sphere.
null v.t.
1. To make negative; also, to destroy. Obs.
2. To
annul; to make void; nullify.
[From Websters1949Unabridged.]
(c) 2004-2008 by
John Van Wie Bergamini.