public function sort( $callback = null , $ascending = true ) {

			if ( null !== $callback && !is_callable( $callback ) ) {
				throw new \browserfs\Exception('Invalid argument $callback: Expected callable( any, any ): int | null' );
			}

			$result = [];

			for ( $i=0; $i<$this->len; $i++ ) {
				$result[] = &$this->items[ $i ];
			}

			if ( is_callable( $callback ) ) {

				usort( $result, $callback );

			} else 
			{

				usort( $result, [ $this, 'compare' ] );

			}

			return new static( $ascending ? $result : array_reverse( $result ) );
		}