Skip to content

Commit

Permalink
Fix documentation for types conforming to ExpressibleByArrayLiteral o…
Browse files Browse the repository at this point in the history
…r ExpressibleByDictionaryLiteral (#82)

# Conflicts:
#	Sources/PriorityQueueModule/Heap+ExpressibleByArrayLiteral.swift
  • Loading branch information
ejmarchant authored and lorentey committed Aug 20, 2021
1 parent 85a2070 commit 5ff8c00
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 14 deletions.
6 changes: 3 additions & 3 deletions Sources/DequeModule/Deque+ExpressibleByArrayLiteral.swift
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ extension Deque: ExpressibleByArrayLiteral {
/// Creates a new deque from the contents of an array literal.
///
/// Do not call this initializer directly. It is used by the compiler when
/// you use an array literal. Instead, create a new set using an array
/// you use an array literal. Instead, create a new deque using an array
/// literal as its value by enclosing a comma-separated list of values in
/// square brackets. You can use an array literal anywhere a set is expected
/// square brackets. You can use an array literal anywhere a deque is expected
/// by the type context.
///
/// - Parameter elements: A variadic list of elements of the new set.
/// - Parameter elements: A variadic list of elements of the new deque.
@inlinable
@inline(__always)
public init(arrayLiteral elements: Element...) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,14 @@ extension OrderedDictionary: ExpressibleByDictionaryLiteral {
/// Creates a new ordered dictionary from the contents of a dictionary
/// literal.
///
/// Duplicate elements in the literal are allowed, but the resulting
/// set will only contain the first occurrence of each.
///
/// Do not call this initializer directly. It is used by the compiler when you
/// use a dictionary literal. Instead, create a new ordered dictionary using a
/// dictionary literal as its value by enclosing a comma-separated list of
/// values in square brackets. You can use an array literal anywhere a set is
/// expected by the type context.
/// key-value pairs in square brackets. You can use a dictionary literal
/// anywhere an ordered dictionary is expected by the type context.
///
/// - Parameter elements: A variadic list of key-value pairs for the new
/// dictionary.
/// ordered dictionary.
///
/// - Complexity: O(`elements.count`) if `Key` implements
/// high-quality hashing.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,16 @@
extension OrderedSet: ExpressibleByArrayLiteral {
/// Creates a new ordered set from the contents of an array literal.
///
/// Duplicate elements in the literal are allowed, but the resulting
/// Duplicate elements in the literal are allowed, but the resulting ordered
/// set will only contain the first occurrence of each.
///
/// Do not call this initializer directly. It is used by the compiler when
/// you use an array literal. Instead, create a new set using an array
/// you use an array literal. Instead, create a new ordered set using an array
/// literal as its value by enclosing a comma-separated list of values in
/// square brackets. You can use an array literal anywhere a set is expected
/// by the type context.
/// square brackets. You can use an array literal anywhere an ordered set is
/// expected by the type context.
///
/// - Parameter elements: A variadic list of elements of the new set.
/// - Parameter elements: A variadic list of elements of the new ordered set.
///
/// - Complexity: O(`elements.count`) if `Element` implements
/// high-quality hashing.
Expand Down

0 comments on commit 5ff8c00

Please sign in to comment.