PatternTest not optimized?
问题 In preparing a response to An unexpected behavior of PatternTest in Mathematica I came across an unexpected Mathematica behavior of my own. Please consider: test = (Print[##]; False) &; MatchQ[{1, 2, 3, 4, 5}, {x__?test, y__}] During evaluation of In[1]:= 1 During evaluation of In[1]:= 1 During evaluation of In[1]:= 1 During evaluation of In[1]:= 1 False Since, as Simon's quote of the documentation concisely states: In a form such as __?test every element in the sequence matched by __ must