Skip to content

Commit 7881dc0

Browse files
committed
Document rationale for Dictionary specialized overloads
1 parent 955d133 commit 7881dc0

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

Sources/Testing/Test+Macro.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -402,7 +402,9 @@ extension Test {
402402
///
403403
/// This initializer overload is specialized for dictionary collections, to
404404
/// efficiently de-structure their elements (which are known to be 2-tuples)
405-
/// when appropriate.
405+
/// when appropriate. This overload is distinct from those for other
406+
/// collections of 2-tuples because the `Element` tuple type for
407+
/// `Dictionary` includes labels (`(key: Key, value: Value)`).
406408
///
407409
/// - Warning: This function is used to implement the `@Test` macro. Do not
408410
/// call it directly.

Sources/Testing/Test.Case.Generator.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,9 @@ extension Test.Case {
228228
///
229229
/// This initializer overload is specialized for dictionary collections, to
230230
/// efficiently de-structure their elements (which are known to be 2-tuples)
231-
/// when appropriate.
231+
/// when appropriate. This overload is distinct from those for other
232+
/// collections of 2-tuples because the `Element` tuple type for
233+
/// `Dictionary` includes labels (`(key: Key, value: Value)`).
232234
init<Key, Value>(
233235
arguments dictionary: Dictionary<Key, Value>,
234236
parameters: [Test.ParameterInfo],

0 commit comments

Comments
 (0)