This is a staging environment. For live and up-to-date package information, visit swiftpackageindex.com.

The Swift Package Index logo.Swift Package Index

Track the adoption of Swift 6 strict concurrency checks for data race safety. How many packages are Ready for Swift 6?

Build Information

Successful build of xml-coding with Swift 6.0 for macOS (SPM).

Swift 6 data race errors: 7

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/adam-fowler/xml-coding.git
Reference: main
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/adam-fowler/xml-coding
 * branch            main       -> FETCH_HEAD
 * [new branch]      main       -> origin/main
HEAD is now at b6a2ae2 Fix decoding of optional attributes (#6)
Cloned https://github.com/adam-fowler/xml-coding.git
Revision (git rev-parse @):
b6a2ae25464959f41cd167047ee47fe5bb681c6c
SUCCESS checkout https://github.com/adam-fowler/xml-coding.git at main
========================================
Build
========================================
Selected platform:         macosSpm
Swift version:             6.0
Building package at path:  $workDir
https://github.com/adam-fowler/xml-coding.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/2] Write sources
[1/2] Write swift-version-6F35C1178C84523A.txt
[3/8] Compiling XMLCoding XMLDecoder.swift
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XMLDecoder.swift:753:17: warning: var '_iso8601Formatter' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
751 | // NOTE: This value is implicitly lazy and _must_ be lazy. We're compiled against the latest SDK (w/ ISO8601DateFormatter), but linked against whichever Foundation the user has. ISO8601DateFormatter might not exist, so we better not hit this code path on an older OS.
752 | @available(macOS 10.12, iOS 10.0, watchOS 3.0, tvOS 10.0, *)
753 | fileprivate var _iso8601Formatter: ISO8601DateFormatter = {
    |                 |- warning: var '_iso8601Formatter' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
    |                 |- note: convert '_iso8601Formatter' to a 'let' constant to make 'Sendable' shared state immutable
    |                 |- note: annotate '_iso8601Formatter' 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
754 |     let formatter = ISO8601DateFormatter()
755 |     formatter.formatOptions = .withInternetDateTime
[4/8] Compiling XMLCoding XML.swift
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XML.swift:39:27: warning: static property 'nodeCompactEmptyElement' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
 33 |
 34 |     /// Options for parsing and outputting XML Data
 35 |     public struct Options : OptionSet {
    |                   `- note: consider making struct 'Options' conform to the 'Sendable' protocol
 36 |         public let rawValue: Int
 37 |
 38 |         /// if an XML Element has no children then output as `<element />`. Default is to output `<element></element>`
 39 |         public static let nodeCompactEmptyElement = Options(rawValue: 1 << 0)
    |                           |- warning: static property 'nodeCompactEmptyElement' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
    |                           |- note: annotate 'nodeCompactEmptyElement' 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
 40 |         /// output XML as human readable
 41 |         public static let nodePrettyPrint = Options(rawValue: 1 << 4)
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XML.swift:41:27: warning: static property 'nodePrettyPrint' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
 33 |
 34 |     /// Options for parsing and outputting XML Data
 35 |     public struct Options : OptionSet {
    |                   `- note: consider making struct 'Options' conform to the 'Sendable' protocol
 36 |         public let rawValue: Int
 37 |
    :
 39 |         public static let nodeCompactEmptyElement = Options(rawValue: 1 << 0)
 40 |         /// output XML as human readable
 41 |         public static let nodePrettyPrint = Options(rawValue: 1 << 4)
    |                           |- warning: static property 'nodePrettyPrint' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
    |                           |- note: annotate 'nodePrettyPrint' 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
 42 |         /// flag that XML Node should be output as CDATA
 43 |         public static let nodeIsCDATA = Options(rawValue: 1 << 5)
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XML.swift:43:27: warning: static property 'nodeIsCDATA' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
 33 |
 34 |     /// Options for parsing and outputting XML Data
 35 |     public struct Options : OptionSet {
    |                   `- note: consider making struct 'Options' conform to the 'Sendable' protocol
 36 |         public let rawValue: Int
 37 |
    :
 41 |         public static let nodePrettyPrint = Options(rawValue: 1 << 4)
 42 |         /// flag that XML Node should be output as CDATA
 43 |         public static let nodeIsCDATA = Options(rawValue: 1 << 5)
    |                           |- warning: static property 'nodeIsCDATA' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
    |                           |- note: annotate 'nodeIsCDATA' 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
 44 |
 45 |         /// when parsing XML preserve the whitespace sections
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XML.swift:46:27: warning: static property 'nodePreserveWhitespace' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
 33 |
 34 |     /// Options for parsing and outputting XML Data
 35 |     public struct Options : OptionSet {
    |                   `- note: consider making struct 'Options' conform to the 'Sendable' protocol
 36 |         public let rawValue: Int
 37 |
    :
 44 |
 45 |         /// when parsing XML preserve the whitespace sections
 46 |         public static let nodePreserveWhitespace = Options(rawValue: 1 << 16)
    |                           |- warning: static property 'nodePreserveWhitespace' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
    |                           |- note: annotate 'nodePreserveWhitespace' 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 |         /// when parsing XML preserve the CDATA text elements
 48 |         public static let nodePreserveCDATA = Options(rawValue: 1 << 18)
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XML.swift:48:27: warning: static property 'nodePreserveCDATA' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
 33 |
 34 |     /// Options for parsing and outputting XML Data
 35 |     public struct Options : OptionSet {
    |                   `- note: consider making struct 'Options' conform to the 'Sendable' protocol
 36 |         public let rawValue: Int
 37 |
    :
 46 |         public static let nodePreserveWhitespace = Options(rawValue: 1 << 16)
 47 |         /// when parsing XML preserve the CDATA text elements
 48 |         public static let nodePreserveCDATA = Options(rawValue: 1 << 18)
    |                           |- warning: static property 'nodePreserveCDATA' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
    |                           |- note: annotate 'nodePreserveCDATA' 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
 49 |
 50 |         public init(rawValue: Int) {
[5/8] Compiling XMLCoding CodableProperties.swift
[6/8] Emitting module XMLCoding
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XML.swift:39:27: warning: static property 'nodeCompactEmptyElement' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
 33 |
 34 |     /// Options for parsing and outputting XML Data
 35 |     public struct Options : OptionSet {
    |                   `- note: consider making struct 'Options' conform to the 'Sendable' protocol
 36 |         public let rawValue: Int
 37 |
 38 |         /// if an XML Element has no children then output as `<element />`. Default is to output `<element></element>`
 39 |         public static let nodeCompactEmptyElement = Options(rawValue: 1 << 0)
    |                           |- warning: static property 'nodeCompactEmptyElement' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
    |                           |- note: annotate 'nodeCompactEmptyElement' 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
 40 |         /// output XML as human readable
 41 |         public static let nodePrettyPrint = Options(rawValue: 1 << 4)
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XML.swift:41:27: warning: static property 'nodePrettyPrint' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
 33 |
 34 |     /// Options for parsing and outputting XML Data
 35 |     public struct Options : OptionSet {
    |                   `- note: consider making struct 'Options' conform to the 'Sendable' protocol
 36 |         public let rawValue: Int
 37 |
    :
 39 |         public static let nodeCompactEmptyElement = Options(rawValue: 1 << 0)
 40 |         /// output XML as human readable
 41 |         public static let nodePrettyPrint = Options(rawValue: 1 << 4)
    |                           |- warning: static property 'nodePrettyPrint' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
    |                           |- note: annotate 'nodePrettyPrint' 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
 42 |         /// flag that XML Node should be output as CDATA
 43 |         public static let nodeIsCDATA = Options(rawValue: 1 << 5)
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XML.swift:43:27: warning: static property 'nodeIsCDATA' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
 33 |
 34 |     /// Options for parsing and outputting XML Data
 35 |     public struct Options : OptionSet {
    |                   `- note: consider making struct 'Options' conform to the 'Sendable' protocol
 36 |         public let rawValue: Int
 37 |
    :
 41 |         public static let nodePrettyPrint = Options(rawValue: 1 << 4)
 42 |         /// flag that XML Node should be output as CDATA
 43 |         public static let nodeIsCDATA = Options(rawValue: 1 << 5)
    |                           |- warning: static property 'nodeIsCDATA' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
    |                           |- note: annotate 'nodeIsCDATA' 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
 44 |
 45 |         /// when parsing XML preserve the whitespace sections
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XML.swift:46:27: warning: static property 'nodePreserveWhitespace' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
 33 |
 34 |     /// Options for parsing and outputting XML Data
 35 |     public struct Options : OptionSet {
    |                   `- note: consider making struct 'Options' conform to the 'Sendable' protocol
 36 |         public let rawValue: Int
 37 |
    :
 44 |
 45 |         /// when parsing XML preserve the whitespace sections
 46 |         public static let nodePreserveWhitespace = Options(rawValue: 1 << 16)
    |                           |- warning: static property 'nodePreserveWhitespace' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
    |                           |- note: annotate 'nodePreserveWhitespace' 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 |         /// when parsing XML preserve the CDATA text elements
 48 |         public static let nodePreserveCDATA = Options(rawValue: 1 << 18)
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XML.swift:48:27: warning: static property 'nodePreserveCDATA' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
 33 |
 34 |     /// Options for parsing and outputting XML Data
 35 |     public struct Options : OptionSet {
    |                   `- note: consider making struct 'Options' conform to the 'Sendable' protocol
 36 |         public let rawValue: Int
 37 |
    :
 46 |         public static let nodePreserveWhitespace = Options(rawValue: 1 << 16)
 47 |         /// when parsing XML preserve the CDATA text elements
 48 |         public static let nodePreserveCDATA = Options(rawValue: 1 << 18)
    |                           |- warning: static property 'nodePreserveCDATA' is not concurrency-safe because non-'Sendable' type 'XML.Options' may have shared mutable state; this is an error in the Swift 6 language mode
    |                           |- note: annotate 'nodePreserveCDATA' 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
 49 |
 50 |         public init(rawValue: Int) {
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XMLDecoder.swift:753:17: warning: var '_iso8601Formatter' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
751 | // NOTE: This value is implicitly lazy and _must_ be lazy. We're compiled against the latest SDK (w/ ISO8601DateFormatter), but linked against whichever Foundation the user has. ISO8601DateFormatter might not exist, so we better not hit this code path on an older OS.
752 | @available(macOS 10.12, iOS 10.0, watchOS 3.0, tvOS 10.0, *)
753 | fileprivate var _iso8601Formatter: ISO8601DateFormatter = {
    |                 |- warning: var '_iso8601Formatter' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
    |                 |- note: convert '_iso8601Formatter' to a 'let' constant to make 'Sendable' shared state immutable
    |                 |- note: annotate '_iso8601Formatter' 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
754 |     let formatter = ISO8601DateFormatter()
755 |     formatter.formatOptions = .withInternetDateTime
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XMLEncoder.swift:693:17: warning: var '_iso8601Formatter' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
691 | // NOTE: This value is implicitly lazy and _must_ be lazy. We're compiled against the latest SDK (w/ ISO8601DateFormatter), but linked against whichever Foundation the user has. ISO8601DateFormatter might not exist, so we better not hit this code path on an older OS.
692 | @available(macOS 10.12, iOS 10.0, watchOS 3.0, tvOS 10.0, *)
693 | fileprivate var _iso8601Formatter: ISO8601DateFormatter = {
    |                 |- warning: var '_iso8601Formatter' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
    |                 |- note: convert '_iso8601Formatter' to a 'let' constant to make 'Sendable' shared state immutable
    |                 |- note: annotate '_iso8601Formatter' 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
694 |     let formatter = ISO8601DateFormatter()
695 |     formatter.formatOptions = .withInternetDateTime
[7/8] Compiling XMLCoding XMLEncoder.swift
/Users/admin/builder/spi-builder-workspace/Sources/XMLCoding/XMLEncoder.swift:693:17: warning: var '_iso8601Formatter' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
691 | // NOTE: This value is implicitly lazy and _must_ be lazy. We're compiled against the latest SDK (w/ ISO8601DateFormatter), but linked against whichever Foundation the user has. ISO8601DateFormatter might not exist, so we better not hit this code path on an older OS.
692 | @available(macOS 10.12, iOS 10.0, watchOS 3.0, tvOS 10.0, *)
693 | fileprivate var _iso8601Formatter: ISO8601DateFormatter = {
    |                 |- warning: var '_iso8601Formatter' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
    |                 |- note: convert '_iso8601Formatter' to a 'let' constant to make 'Sendable' shared state immutable
    |                 |- note: annotate '_iso8601Formatter' 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
694 |     let formatter = ISO8601DateFormatter()
695 |     formatter.formatOptions = .withInternetDateTime
[8/8] Compiling XMLCoding CollectionCoders.swift
Build complete! (17.68s)
Build complete.
{
  "dependencies" : [
  ],
  "manifest_display_name" : "xml-coding",
  "name" : "xml-coding",
  "path" : "/Users/admin/builder/spi-builder-workspace",
  "platforms" : [
  ],
  "products" : [
    {
      "name" : "XMLCoding",
      "targets" : [
        "XMLCoding"
      ],
      "type" : {
        "library" : [
          "automatic"
        ]
      }
    }
  ],
  "targets" : [
    {
      "c99name" : "XMLCodingTests",
      "module_type" : "SwiftTarget",
      "name" : "XMLCodingTests",
      "path" : "Tests/XMLCodingTests",
      "sources" : [
        "XMLEncoderTests.swift",
        "XMLTests.swift"
      ],
      "target_dependencies" : [
        "XMLCoding"
      ],
      "type" : "test"
    },
    {
      "c99name" : "XMLCoding",
      "module_type" : "SwiftTarget",
      "name" : "XMLCoding",
      "path" : "Sources/XMLCoding",
      "product_memberships" : [
        "XMLCoding"
      ],
      "sources" : [
        "CodableProperties/CodableProperties.swift",
        "CodableProperties/CollectionCoders.swift",
        "XML.swift",
        "XMLDecoder.swift",
        "XMLEncoder.swift"
      ],
      "type" : "library"
    }
  ],
  "tools_version" : "5.1"
}
Done.
This is a staging environment. For live and up-to-date package information, visit swiftpackageindex.com.