Skip to content

Commit fb8eabe

Browse files
committed
AST: switch to std::sort from llvm::array_pod_sort
Swap the `array_pod_sort` to `sort`. `array_pod_sort` is meant to be used with POD types only. Switching to `std:sort` should be slightly faster, and more importantly, allows the emission of the warnings on Windows to be sorted identically to Linux and macOS.
1 parent ecb539f commit fb8eabe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/AST/GenericSignatureBuilder.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6014,7 +6014,7 @@ Constraint<T> GenericSignatureBuilder::checkConstraintList(
60146014
}
60156015

60166016
// Sort the constraints, so we get a deterministic ordering of diagnostics.
6017-
llvm::array_pod_sort(constraints.begin(), constraints.end());
6017+
std::sort(constraints.begin(), constraints.end());
60186018

60196019
// Find a representative constraint.
60206020
auto representativeConstraint =

0 commit comments

Comments
 (0)