Skip to content

Commit 7df3695

Browse files
committed
Go over Quiet and All documentation and tests
1 parent 84a9d7a commit 7df3695

2 files changed

Lines changed: 11 additions & 2 deletions

File tree

mathics/builtin/inout.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1516,9 +1516,18 @@ class Quiet(Builtin):
15161516
<dd>evaluates $expr$, with messages $off$ being suppressed, but messages $on$ being displayed.
15171517
</dl>
15181518
1519+
Evaluate without generating messages:
1520+
>> Quiet[1/0]
1521+
= ComplexInfinity
1522+
1523+
Same as above:
1524+
>> Quiet[1/0, All]
1525+
= ComplexInfinity
1526+
15191527
>> a::b = "Hello";
15201528
>> Quiet[x+x, {a::b}]
15211529
= 2 x
1530+
15221531
>> Quiet[Message[a::b]; x+x, {a::b}]
15231532
= 2 x
15241533
@@ -1527,7 +1536,7 @@ class Quiet(Builtin):
15271536
: Hello
15281537
= 2 x
15291538
1530-
>> Quiet[expr, All, All]
1539+
#> Quiet[expr, All, All]
15311540
: Arguments 2 and 3 of Quiet[expr, All, All] should not both be All.
15321541
= Quiet[expr, All, All]
15331542
>> Quiet[x + x, {a::b}, {a::b}]

mathics/builtin/lists.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,7 @@ class All(Predefined):
380380
"""
381381
<dl>
382382
<dt>'All'
383-
<dd>is a possible value for 'Span' and 'Quiet'.
383+
<dd>is a possible option value for 'Span' and 'Quiet'. 'All' specifies all parts a a particular level.
384384
</dl>
385385
"""
386386
attributes = ("Unprotected",)

0 commit comments

Comments
 (0)