code: private function isStringPartToken(Token $token)
      {
          return $token->isGivenKind(T_ENCAPSED_AND_WHITESPACE)
              || $token->isGivenKind(T_START_HEREDOC)
              || '"' === $token->getContent()
              || 'b"' === strtolower($token->getContent())
          ;
      }
docs: Check if token is a part of a string.
  
  @param Token $token The token to check
  
  @return bool