You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I’m extending Squiz.WhiteSpace.OperatorSpacing to check for whitespace around elvis operator (?:) and null coalescing operator (??). I already managed to get the sniff to work correctly with elvis operator. The sniff is registered to listen to tokens T_INLINE_THEN and T_INLINE_ELSE which match the elvis operator correctly. I would have guessed that null coalescing operator would be equal to two T_INLINE_THEN tokens, but instead the operator is not detected at all. I could not find a token for the operator in CodeSniffer/Tokens.php.