Build Information
Successful build of UBJSONSerialization with Swift 6.0 for macOS (SPM).
Swift 6 data race errors: 18
Build Command
env DEVELOPER_DIR=/Applications/Xcode-15.3.0.app xcrun --toolchain org.swift.600202405261a swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
Build Log
========================================
RunAll
========================================
Builder version: 4.40.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/frizlab/ubjsonserialization.git
Reference: main
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/frizlab/ubjsonserialization
* branch main -> FETCH_HEAD
* [new branch] main -> origin/main
HEAD is now at 9c1a270 Fix trivial warnings
Cloned https://github.com/frizlab/ubjsonserialization.git
Revision (git rev-parse @):
9c1a27000da268931345b131d4105ca1ff9153b5
SUCCESS checkout https://github.com/frizlab/ubjsonserialization.git at main
========================================
Build
========================================
Selected platform: macosSpm
Swift version: 6.0
Building package at path: $workDir
https://github.com/frizlab/ubjsonserialization.git
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-15.3.0.app xcrun --toolchain org.swift.600202405261a swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
Building for debugging...
[0/3] Write sources
[2/3] Write swift-version-6F35C1178C84523A.txt
[4/13] Compiling StreamReader GenericStreamReader.swift
[5/13] Compiling StreamReader StreamReaderErrors.swift
[6/13] Compiling StreamReader InputStreamReader.swift
[7/13] Compiling StreamReader FileDescriptorReader.swift
[8/13] Compiling StreamReader URLSessionStreamTaskReader.swift
[9/13] Compiling StreamReader Matching.swift
[10/13] Compiling StreamReader StreamReader.swift
[11/13] Compiling StreamReader DataReader.swift
[12/13] Emitting module StreamReader
[13/13] Compiling StreamReader FileHandleReader.swift
[14/20] Compiling UBJSONSerialization Utils.swift
[15/20] Compiling UBJSONSerialization Nop.swift
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/Nop.swift:21:20: warning: static property 'sharedNop' is not concurrency-safe because non-'Sendable' type 'Nop' may have shared mutable state; this is an error in the Swift 6 language mode
17 |
18 | It should be used pretty much only when we have proper streaming support to send ``Nop`` values in a stream to keep it alive. */
19 | public struct Nop : Equatable {
| `- note: consider making struct 'Nop' conform to the 'Sendable' protocol
20 |
21 | public static let sharedNop = Nop()
| |- warning: static property 'sharedNop' is not concurrency-safe because non-'Sendable' type 'Nop' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'sharedNop' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
22 |
23 | public static func ==(lhs: Nop, rhs: Nop) -> Bool {return true}
[16/20] Compiling UBJSONSerialization UBJSONSerialization.swift
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:27:21: warning: static property 'keepIntPrecision' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSerialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
25 | /**
26 | Do not convert Int8, Int16, etc. to Int. */
27 | public static let keepIntPrecision = ReadingOptions(rawValue: 1 << 0)
| |- warning: static property 'keepIntPrecision' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'keepIntPrecision' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
28 |
29 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:38:21: warning: static property 'allowHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSerialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
36 | You can use something like [BigInt](https://github.com/lorentey/BigInt) to handle big integers.
37 | Note high-precision numbers can also be decimals. */
38 | public static let allowHighPrecisionNumbers = ReadingOptions(rawValue: 1 << 1)
| |- warning: static property 'allowHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'allowHighPrecisionNumbers' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
39 |
40 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:46:21: warning: static property 'returnNopElements' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSerialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
44 | - Note: This applies only to `No-Op` elements at the root of the UBJSON document being deserialized.
45 | For embedded `No-Op`s, see `.keepNopElementsInArrays`. */
46 | public static let returnNopElements = ReadingOptions(rawValue: 1 << 2)
| |- warning: static property 'returnNopElements' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'returnNopElements' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
47 |
48 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:57:21: warning: static property 'keepNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSerialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
55 | - Note: ``Nop`` in a dictionary has no meaning and is always **skipped**
56 | (it is NOT (AFAICT) invalid to have a Nop element before a value in a dictionary in a non-optimized dictionary; the `No-Op` is simply skipped). */
57 | public static let keepNopElementsInArrays = ReadingOptions(rawValue: 1 << 3)
| |- warning: static property 'keepNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'keepNopElementsInArrays' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
58 |
59 | public init(rawValue v: Int) {
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:72:21: warning: static property 'normalizeHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
63 | }
64 |
65 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
66 |
67 | public let rawValue: Int
:
70 | Normalize the representation of high precisions numbers before serialization.
71 | See ``HighPrecisionNumber`` for more information about normalization. */
72 | public static let normalizeHighPrecisionNumbers = WritingOptions(rawValue: 1 << 0)
| |- warning: static property 'normalizeHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'normalizeHighPrecisionNumbers' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
73 |
74 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:79:21: warning: static property 'optimizeIntsForSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
63 | }
64 |
65 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
66 |
67 | public let rawValue: Int
:
77 | - Note: This option is always on for `Int` objects.
78 | It has to be specifically asked only for other ints types (`Int8`, `Int16`, etc.) */
79 | public static let optimizeIntsForSize = WritingOptions(rawValue: 1 << 1)
| |- warning: static property 'optimizeIntsForSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'optimizeIntsForSize' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
80 |
81 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:87:21: warning: static property 'skipNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
63 | }
64 |
65 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
66 |
67 | public let rawValue: Int
:
85 | - Note: This option is expensive (has to do a first pass through the whole serialized object graph before serialization).
86 | Only use it in case there is a chance your data contains `No-op` elements and you want it dropped. */
87 | public static let skipNopElementsInArrays = WritingOptions(rawValue: 1 << 2)
| |- warning: static property 'skipNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'skipNopElementsInArrays' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
88 |
89 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:98:21: warning: static property 'enableContainerOptimization' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
63 | }
64 |
65 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
66 |
67 | public let rawValue: Int
:
96 | because I don’t think it has any advantages over the JSON-like representation.
97 | I’d be happy to change my mind if somebody can give me good arguments in favor of this optimization :) */
98 | public static let enableContainerOptimization = WritingOptions(rawValue: 1 << 3)
| |- warning: static property 'enableContainerOptimization' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'enableContainerOptimization' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
99 |
100 | public init(rawValue v: Int) {
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/Nop.swift:21:20: warning: static property 'sharedNop' is not concurrency-safe because non-'Sendable' type 'Nop' may have shared mutable state; this is an error in the Swift 6 language mode
17 |
18 | It should be used pretty much only when we have proper streaming support to send ``Nop`` values in a stream to keep it alive. */
19 | public struct Nop : Equatable {
| `- note: consider making struct 'Nop' conform to the 'Sendable' protocol
20 |
21 | public static let sharedNop = Nop()
| |- warning: static property 'sharedNop' is not concurrency-safe because non-'Sendable' type 'Nop' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'sharedNop' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
22 |
23 | public static func ==(lhs: Nop, rhs: Nop) -> Bool {return true}
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:881:10: warning: type 'S.Element' is not optional, value can never be nil; this is an error in the Swift 6 language mode
879 | case _ as Nop: return nil
880 |
881 | case nil: newType = .null
| `- warning: type 'S.Element' is not optional, value can never be nil; this is an error in the Swift 6 language mode
882 | case let b as Bool where b: newType = .`true`
883 | case let b as Bool where !b: newType = .`false`
[17/20] Compiling UBJSONSerialization UBJSONSpec8Serialization.swift
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:27:21: warning: static property 'keepIntPrecision' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSpec8Serialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
25 | /**
26 | Do not convert Int8, Int16, etc. to Int. */
27 | public static let keepIntPrecision = ReadingOptions(rawValue: 1 << 0)
| |- warning: static property 'keepIntPrecision' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'keepIntPrecision' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
28 |
29 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:38:21: warning: static property 'allowHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSpec8Serialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
36 | You can use something like [BigInt](https://github.com/lorentey/BigInt) to handle big integers.
37 | Note high-precision numbers can also be decimals. */
38 | public static let allowHighPrecisionNumbers = ReadingOptions(rawValue: 1 << 1)
| |- warning: static property 'allowHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'allowHighPrecisionNumbers' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
39 |
40 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:46:21: warning: static property 'returnNopElements' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSpec8Serialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
44 | - Note: This applies only to `No-Op` elements at the root of the UBJSON document being deserialized.
45 | For embedded `No-Op`s, see `.keepNopElementsInArrays`. */
46 | public static let returnNopElements = ReadingOptions(rawValue: 1 << 2)
| |- warning: static property 'returnNopElements' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'returnNopElements' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
47 |
48 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:58:21: warning: static property 'keepNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSpec8Serialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
56 | `No-Op` in a dictionary has no meaning and is always **skipped** for indeterminate size dictionaries
57 | (`No-Op` is invalid in a dictionary whose size is known). */
58 | public static let keepNopElementsInArrays = ReadingOptions(rawValue: 1 << 3)
| |- warning: static property 'keepNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'keepNopElementsInArrays' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
59 |
60 | public init(rawValue v: Int) {
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:73:21: warning: static property 'normalizeHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
64 | }
65 |
66 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
67 |
68 | public let rawValue: Int
:
71 | Normalize the representation of high precisions numbers before serialization.
72 | See the doc of HighPrecisionNumber for more information about normalization. */
73 | public static let normalizeHighPrecisionNumbers = WritingOptions(rawValue: 1 << 0)
| |- warning: static property 'normalizeHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'normalizeHighPrecisionNumbers' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
74 |
75 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:80:21: warning: static property 'optimizeIntsForSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
64 | }
65 |
66 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
67 |
68 | public let rawValue: Int
:
78 | - Note: This option is always on for `Int` objects.
79 | It has to be specifically asked only for other ints types (`Int8`, `Int16`, etc.) */
80 | public static let optimizeIntsForSize = WritingOptions(rawValue: 1 << 1)
| |- warning: static property 'optimizeIntsForSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'optimizeIntsForSize' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
81 |
82 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:88:21: warning: static property 'skipNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
64 | }
65 |
66 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
67 |
68 | public let rawValue: Int
:
86 | - Note: This option is expensive (has to do a first pass through the whole serialized object graph before serialization).
87 | Only use it in case there is a chance your data contains `No-op` elements and you want it dropped. */
88 | public static let skipNopElementsInArrays = WritingOptions(rawValue: 1 << 2)
| |- warning: static property 'skipNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'skipNopElementsInArrays' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
89 |
90 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:93:21: warning: static property 'declareContainerWithUnknownSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
64 | }
65 |
66 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
67 |
68 | public let rawValue: Int
:
91 | Declare the containers to have an unknown size in the serialized data.
92 | Mostly useful if we want to implement proper streaming support later. */
93 | public static let declareContainerWithUnknownSize = WritingOptions(rawValue: 1 << 3)
| |- warning: static property 'declareContainerWithUnknownSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'declareContainerWithUnknownSize' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
94 |
95 | public init(rawValue v: Int) {
[18/20] Compiling UBJSONSerialization HighPrecisionNumber.swift
[19/20] Emitting module UBJSONSerialization
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/Nop.swift:21:20: warning: static property 'sharedNop' is not concurrency-safe because non-'Sendable' type 'Nop' may have shared mutable state; this is an error in the Swift 6 language mode
17 |
18 | It should be used pretty much only when we have proper streaming support to send ``Nop`` values in a stream to keep it alive. */
19 | public struct Nop : Equatable {
| `- note: consider making struct 'Nop' conform to the 'Sendable' protocol
20 |
21 | public static let sharedNop = Nop()
| |- warning: static property 'sharedNop' is not concurrency-safe because non-'Sendable' type 'Nop' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'sharedNop' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
22 |
23 | public static func ==(lhs: Nop, rhs: Nop) -> Bool {return true}
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:27:21: warning: static property 'keepIntPrecision' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSerialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
25 | /**
26 | Do not convert Int8, Int16, etc. to Int. */
27 | public static let keepIntPrecision = ReadingOptions(rawValue: 1 << 0)
| |- warning: static property 'keepIntPrecision' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'keepIntPrecision' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
28 |
29 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:38:21: warning: static property 'allowHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSerialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
36 | You can use something like [BigInt](https://github.com/lorentey/BigInt) to handle big integers.
37 | Note high-precision numbers can also be decimals. */
38 | public static let allowHighPrecisionNumbers = ReadingOptions(rawValue: 1 << 1)
| |- warning: static property 'allowHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'allowHighPrecisionNumbers' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
39 |
40 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:46:21: warning: static property 'returnNopElements' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSerialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
44 | - Note: This applies only to `No-Op` elements at the root of the UBJSON document being deserialized.
45 | For embedded `No-Op`s, see `.keepNopElementsInArrays`. */
46 | public static let returnNopElements = ReadingOptions(rawValue: 1 << 2)
| |- warning: static property 'returnNopElements' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'returnNopElements' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
47 |
48 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:57:21: warning: static property 'keepNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSerialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
55 | - Note: ``Nop`` in a dictionary has no meaning and is always **skipped**
56 | (it is NOT (AFAICT) invalid to have a Nop element before a value in a dictionary in a non-optimized dictionary; the `No-Op` is simply skipped). */
57 | public static let keepNopElementsInArrays = ReadingOptions(rawValue: 1 << 3)
| |- warning: static property 'keepNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'keepNopElementsInArrays' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
58 |
59 | public init(rawValue v: Int) {
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:72:21: warning: static property 'normalizeHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
63 | }
64 |
65 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
66 |
67 | public let rawValue: Int
:
70 | Normalize the representation of high precisions numbers before serialization.
71 | See ``HighPrecisionNumber`` for more information about normalization. */
72 | public static let normalizeHighPrecisionNumbers = WritingOptions(rawValue: 1 << 0)
| |- warning: static property 'normalizeHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'normalizeHighPrecisionNumbers' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
73 |
74 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:79:21: warning: static property 'optimizeIntsForSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
63 | }
64 |
65 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
66 |
67 | public let rawValue: Int
:
77 | - Note: This option is always on for `Int` objects.
78 | It has to be specifically asked only for other ints types (`Int8`, `Int16`, etc.) */
79 | public static let optimizeIntsForSize = WritingOptions(rawValue: 1 << 1)
| |- warning: static property 'optimizeIntsForSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'optimizeIntsForSize' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
80 |
81 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:87:21: warning: static property 'skipNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
63 | }
64 |
65 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
66 |
67 | public let rawValue: Int
:
85 | - Note: This option is expensive (has to do a first pass through the whole serialized object graph before serialization).
86 | Only use it in case there is a chance your data contains `No-op` elements and you want it dropped. */
87 | public static let skipNopElementsInArrays = WritingOptions(rawValue: 1 << 2)
| |- warning: static property 'skipNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'skipNopElementsInArrays' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
88 |
89 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerialization.swift:98:21: warning: static property 'enableContainerOptimization' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
63 | }
64 |
65 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
66 |
67 | public let rawValue: Int
:
96 | because I don’t think it has any advantages over the JSON-like representation.
97 | I’d be happy to change my mind if somebody can give me good arguments in favor of this optimization :) */
98 | public static let enableContainerOptimization = WritingOptions(rawValue: 1 << 3)
| |- warning: static property 'enableContainerOptimization' is not concurrency-safe because non-'Sendable' type 'UBJSONSerialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'enableContainerOptimization' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
99 |
100 | public init(rawValue v: Int) {
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerializationErrors.swift:49:7: warning: associated value 'invalidUBJSONObject(invalidElement:)' of 'Sendable'-conforming enum 'UBJSONSerializationError' has non-sendable type 'Any'; this is an error in the Swift 6 language mode
47 | An invalid UBJSON object was given to be serialized.
48 | The invalid element is passed in argument to this error. */
49 | case invalidUBJSONObject(invalidElement: Any)
| `- warning: associated value 'invalidUBJSONObject(invalidElement:)' of 'Sendable'-conforming enum 'UBJSONSerializationError' has non-sendable type 'Any'; this is an error in the Swift 6 language mode
50 |
51 | /* Spec 8 error */
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:27:21: warning: static property 'keepIntPrecision' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSpec8Serialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
25 | /**
26 | Do not convert Int8, Int16, etc. to Int. */
27 | public static let keepIntPrecision = ReadingOptions(rawValue: 1 << 0)
| |- warning: static property 'keepIntPrecision' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'keepIntPrecision' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
28 |
29 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:38:21: warning: static property 'allowHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSpec8Serialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
36 | You can use something like [BigInt](https://github.com/lorentey/BigInt) to handle big integers.
37 | Note high-precision numbers can also be decimals. */
38 | public static let allowHighPrecisionNumbers = ReadingOptions(rawValue: 1 << 1)
| |- warning: static property 'allowHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'allowHighPrecisionNumbers' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
39 |
40 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:46:21: warning: static property 'returnNopElements' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSpec8Serialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
44 | - Note: This applies only to `No-Op` elements at the root of the UBJSON document being deserialized.
45 | For embedded `No-Op`s, see `.keepNopElementsInArrays`. */
46 | public static let returnNopElements = ReadingOptions(rawValue: 1 << 2)
| |- warning: static property 'returnNopElements' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'returnNopElements' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
47 |
48 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:58:21: warning: static property 'keepNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
19 | final public class UBJSONSpec8Serialization {
20 |
21 | public struct ReadingOptions : OptionSet {
| `- note: consider making struct 'ReadingOptions' conform to the 'Sendable' protocol
22 |
23 | public let rawValue: Int
:
56 | `No-Op` in a dictionary has no meaning and is always **skipped** for indeterminate size dictionaries
57 | (`No-Op` is invalid in a dictionary whose size is known). */
58 | public static let keepNopElementsInArrays = ReadingOptions(rawValue: 1 << 3)
| |- warning: static property 'keepNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.ReadingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'keepNopElementsInArrays' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
59 |
60 | public init(rawValue v: Int) {
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:73:21: warning: static property 'normalizeHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
64 | }
65 |
66 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
67 |
68 | public let rawValue: Int
:
71 | Normalize the representation of high precisions numbers before serialization.
72 | See the doc of HighPrecisionNumber for more information about normalization. */
73 | public static let normalizeHighPrecisionNumbers = WritingOptions(rawValue: 1 << 0)
| |- warning: static property 'normalizeHighPrecisionNumbers' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'normalizeHighPrecisionNumbers' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
74 |
75 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:80:21: warning: static property 'optimizeIntsForSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
64 | }
65 |
66 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
67 |
68 | public let rawValue: Int
:
78 | - Note: This option is always on for `Int` objects.
79 | It has to be specifically asked only for other ints types (`Int8`, `Int16`, etc.) */
80 | public static let optimizeIntsForSize = WritingOptions(rawValue: 1 << 1)
| |- warning: static property 'optimizeIntsForSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'optimizeIntsForSize' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
81 |
82 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:88:21: warning: static property 'skipNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
64 | }
65 |
66 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
67 |
68 | public let rawValue: Int
:
86 | - Note: This option is expensive (has to do a first pass through the whole serialized object graph before serialization).
87 | Only use it in case there is a chance your data contains `No-op` elements and you want it dropped. */
88 | public static let skipNopElementsInArrays = WritingOptions(rawValue: 1 << 2)
| |- warning: static property 'skipNopElementsInArrays' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'skipNopElementsInArrays' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
89 |
90 | /**
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSpec8Serialization.swift:93:21: warning: static property 'declareContainerWithUnknownSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
64 | }
65 |
66 | public struct WritingOptions : OptionSet {
| `- note: consider making struct 'WritingOptions' conform to the 'Sendable' protocol
67 |
68 | public let rawValue: Int
:
91 | Declare the containers to have an unknown size in the serialized data.
92 | Mostly useful if we want to implement proper streaming support later. */
93 | public static let declareContainerWithUnknownSize = WritingOptions(rawValue: 1 << 3)
| |- warning: static property 'declareContainerWithUnknownSize' is not concurrency-safe because non-'Sendable' type 'UBJSONSpec8Serialization.WritingOptions' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'declareContainerWithUnknownSize' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
94 |
95 | public init(rawValue v: Int) {
[20/20] Compiling UBJSONSerialization UBJSONSerializationErrors.swift
/Users/admin/builder/spi-builder-workspace/Sources/UBJSONSerialization/UBJSONSerializationErrors.swift:49:7: warning: associated value 'invalidUBJSONObject(invalidElement:)' of 'Sendable'-conforming enum 'UBJSONSerializationError' has non-sendable type 'Any'; this is an error in the Swift 6 language mode
47 | An invalid UBJSON object was given to be serialized.
48 | The invalid element is passed in argument to this error. */
49 | case invalidUBJSONObject(invalidElement: Any)
| `- warning: associated value 'invalidUBJSONObject(invalidElement:)' of 'Sendable'-conforming enum 'UBJSONSerializationError' has non-sendable type 'Any'; this is an error in the Swift 6 language mode
50 |
51 | /* Spec 8 error */
Build complete! (26.73s)
Fetching https://github.com/Frizlab/stream-reader.git
[1/995] Fetching stream-reader
Fetched https://github.com/Frizlab/stream-reader.git from cache (0.88s)
Computing version for https://github.com/Frizlab/stream-reader.git
Computed https://github.com/Frizlab/stream-reader.git at 3.5.0 (0.69s)
Creating working copy for https://github.com/Frizlab/stream-reader.git
Working copy of https://github.com/Frizlab/stream-reader.git resolved at 3.5.0
Build complete.
{
"dependencies" : [
{
"identity" : "stream-reader",
"requirement" : {
"range" : [
{
"lower_bound" : "3.0.0",
"upper_bound" : "4.0.0"
}
]
},
"type" : "sourceControl",
"url" : "https://github.com/Frizlab/stream-reader.git"
}
],
"manifest_display_name" : "UBJSONSerialization",
"name" : "UBJSONSerialization",
"path" : "/Users/admin/builder/spi-builder-workspace",
"platforms" : [
],
"products" : [
{
"name" : "UBJSONSerialization",
"targets" : [
"UBJSONSerialization"
],
"type" : {
"library" : [
"automatic"
]
}
}
],
"targets" : [
{
"c99name" : "UBJSONSerializationTests",
"module_type" : "SwiftTarget",
"name" : "UBJSONSerializationTests",
"path" : "Tests/UBJSONSerializationTests",
"sources" : [
"HighPrecisionNumberTests.swift",
"TestHelpers.swift",
"UBJSONSerializationTests.swift",
"UBJSONSpec8SerializationTests.swift"
],
"target_dependencies" : [
"UBJSONSerialization"
],
"type" : "test"
},
{
"c99name" : "UBJSONSerialization",
"module_type" : "SwiftTarget",
"name" : "UBJSONSerialization",
"path" : "Sources/UBJSONSerialization",
"product_dependencies" : [
"StreamReader"
],
"product_memberships" : [
"UBJSONSerialization"
],
"sources" : [
"HighPrecisionNumber.swift",
"Nop.swift",
"UBJSONSerialization.swift",
"UBJSONSerializationErrors.swift",
"UBJSONSpec8Serialization.swift",
"Utils.swift"
],
"type" : "library"
}
],
"tools_version" : "5.1"
}
Done.