I have some package code that does rather complex multi-context evaluation, and I know it's going to throw warnings about shadowed symbols. The shadowing isn't actually a problem. For the end-user's sake, I want to suppress these warnings.
Quiet
can suppress all messages, which is too heavy-handed. Other kinds of messages might be important and should be reported.
Quiet
can also suppress specific named messages, which is too precise. I don't want to name the specific symbols that might be shadowed, for two reasons: I can't necessarily predict them, and naming the symbols explicitly adds their names to a context that only exacerbates the shadowing problem.
What I would really like to do is to call Quiet[stuffToEvaluate,{*::shdw}]
in order to suppress the shadowing message for any symbol, but Mathematica doesn't seem to accept a wildcard there. None of the message groups listed in $MessageGroups
is helpful, either.
Any suggestions, o sages?
Off
andOn
withGeneral::shdw
, which might work; but I second Leonid's concerns. $\endgroup$LinkCreate
to avoid these problems, but that will take some time to figure out and my students need a new assignment yesterday. $\endgroup$