From 61d5255ef3d4b841c8417d1647d04aab02c3524c Mon Sep 17 00:00:00 2001 From: Saleem Abdulrasool Date: Wed, 28 Apr 2021 08:46:13 -0700 Subject: [PATCH] swift-doc: load FoundationNetworking whenever possible Change the condition from being a platform specific check to whether the module is available. This module is meant to be used on all non-Darwin platforms. This repairs fetching the CSS content when using swift-doc on a Windows host. --- Sources/swift-doc/Subcommands/Generate.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/swift-doc/Subcommands/Generate.swift b/Sources/swift-doc/Subcommands/Generate.swift index 82c9ef32..3aa48e88 100644 --- a/Sources/swift-doc/Subcommands/Generate.swift +++ b/Sources/swift-doc/Subcommands/Generate.swift @@ -5,7 +5,7 @@ import SwiftMarkup import SwiftSemantics import struct SwiftSemantics.Protocol -#if os(Linux) +#if canImport(FoundationNetworking) import FoundationNetworking #endif