Skip to content

Commit 15073e8

Browse files
committed
Improve documentation for internal IfConfigFunctions.
1 parent 19ed1e8 commit 15073e8

File tree

1 file changed

+14
-12
lines changed

1 file changed

+14
-12
lines changed

Sources/SwiftIfConfig/IfConfigFunctions.swift

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,42 +12,44 @@
1212

1313
/// Enum capturing all of the functions that can be used in an `#if` condition.
1414
enum IfConfigFunctions: String {
15-
/// A check for a specific attribute.
15+
/// A check for a specific attribute via `hasAttribute(<name>)`.
1616
case hasAttribute
1717

18-
/// A check for a specific named feature.
18+
/// A check for a specific named feature via `hasFeature(<name>)`.
1919
case hasFeature
2020

21-
/// A check for the Swift language version.
21+
/// A check for the Swift language version via `swift(>=version).`
2222
case swift
2323

24-
/// A check for the Swift compiler version.
24+
/// A check for the Swift compiler version via `compiler(>=version)`.
2525
case compiler
2626

27-
/// A check to determine whether a given module can be imported.
27+
/// A check to determine whether a given module can be imported via `canImport(<import path>)`.
2828
case canImport
2929

30-
/// A check for the target Operating System kind (e.g., Linux, iOS).
30+
/// A check for the target Operating System kind (e.g., Linux, iOS) via `os(<name>)`
3131
case os
3232

33-
/// A check for the target architecture (e.g., arm64, x86_64).
33+
/// A check for the target architecture (e.g., arm64, x86_64) via `arch(<name>)`.
3434
case arch
3535

36-
/// A check for the target environment (e.g., simulator).
36+
/// A check for the target environment (e.g., simulator) via `targetEnvironment(<environment>)`.
3737
case targetEnvironment
3838

39-
/// A historical check against a specific compiler build version.
39+
/// A historical check against a specific compiler build version via `_compiler_version("<version>")`.
4040
case _compiler_version
4141

42-
/// A check for the target endianness (e.g., big or little)
42+
/// A check for the target endianness (e.g., big or little) via `_endian(big|little)`.
4343
case _endian
4444

4545
/// A check for the target bit width of a pointer (e.g., _64)
4646
case _pointerBitWidth
4747

48-
/// A check for the target runtime paired with the Swift runtime (e.g., _ObjC).
48+
/// A check for the target runtime paired with the Swift runtime (e.g., _ObjC)
49+
/// via `_runtime(<name>)`.
4950
case _runtime
5051

51-
/// A check for the target's pointer authentication scheme (e.g., _arm64e).
52+
/// A check for the target's pointer authentication scheme (e.g., _arm64e)
53+
/// via `_ptrauth(<name>)`.
5254
case _ptrauth
5355
}

0 commit comments

Comments
 (0)