Optional::opdef
Details
-
- This message is generated when the second argument in Optional contains pattern expressions.
- The second argument in Optional is the default value to use for the pattern.
- This message is a warning about a potentially ambiguous pattern. The message can be ignored if the use of a pattern expression as a default value is intentional. The pattern is used as specified despite the warning message.
- Pattern expressions are expressions such as Blank[] (_) and Alternatives[x,y] (x|y) that are intended for matching expressions other than themselves.
- The pattern Optional[p,v] is commonly entered using the notation p:v.
- Off[message] switches off the message; On[message] switches it on. For example: Off[Optional::opdef].