AlphabeticalComparator.php 274 B

123456789101112131415
  1. <?php
  2. declare(strict_types=1);
  3. namespace Doctrine\Migrations\Version;
  4. use function strcmp;
  5. final class AlphabeticalComparator implements Comparator
  6. {
  7. public function compare(Version $a, Version $b): int
  8. {
  9. return strcmp((string) $a, (string) $b);
  10. }
  11. }