[Collections] Allow determining if internal checking is enabled

In the benchmark target, complain loudly if consistency checks
are enabled.
This commit is contained in:
Karoy Lorentey committed 2022-09-19 21:25:07 -07:00
1 parent 53895c6537
commit 12e3867ccb
6 files changed
+53 -4

No files matched your search

+6
View File
@@ -9,10 +9,16 @@
//
//===----------------------------------------------------------------------===//
import _CollectionsUtilities
// This file contains exported but non-public entry points to support clear box
// testing.
extension Deque {
public static var _isConsistencyCheckingEnabled: Bool {
_isCollectionsInternalCheckingEnabled
}
/// The maximum number of elements this deque is currently able to store
/// without reallocating its storage buffer.
///