original_string: public function andSort(Sort $sort = null) : Sort
      {
          if ($sort === null) {
              return $this;
          }
          $orders = $this->orders;
          foreach ($sort as $order) {
              $orders[] = $order;
          }
          return new Sort($orders);
      }
code: public function andSort(Sort $sort = null) : Sort
      {
          if ($sort === null) {
              return $this;
          }
          $orders = $this->orders;
          foreach ($sort as $order) {
              $orders[] = $order;
          }
          return new Sort($orders);
      }
code_tokens: public function andSort ( Sort $ sort = null ) : Sort { if ( $ sort === null ) { return $ this ; } $ orders = $ this -> orders ; foreach ( $ sort as $ order ) { $ orders [ ] = $ order ; } return new Sort ( $ orders ) ; }
docstring: Does not modifies the object itself,
  will return a new instance instead.
  
  @param Sort $sort
  @return Sort
docstring_tokens: Does not modifies the object itself will return a new instance instead .