Skip to content

Commit

Permalink
fix xcode 16 build failure
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrew Farquharson authored and Andrew Farquharson committed Oct 11, 2024
1 parent f0cdf12 commit 09c0832
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ let package = Package(
.library(name: "SwiftMarkdown", targets: ["SwiftMarkdown"]),
],
dependencies: [
.package(url: "https://github.com/brokenhandsio/cmark-gfm.git", from: "2.1.0"),
.package(url: "https://github.com/apple/swift-cmark.git", from: "0.5.0"),
],
targets: [
.target(name: "SwiftMarkdown", dependencies: ["cmark"]),
.target(name: "SwiftMarkdown", dependencies: ["cmark-gfm"]),
.testTarget(name: "SwiftMarkdownTests", dependencies: ["SwiftMarkdown"]),
]
)
4 changes: 2 additions & 2 deletions Sources/SwiftMarkdown/SwiftMarkdown.swift
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import cmark
import cmark_gfm
#if os(Android) || os(Linux)
import Glibc
#endif
Expand Down Expand Up @@ -28,7 +28,7 @@ public func markdownToHTML(_ str: String, options: MarkdownOptions = [.safe]) th
var buffer: String?
try str.withCString {

guard let buf = cmark_gfm_markdown_to_html($0, Int(strlen($0)), options.rawValue) else {
guard let buf = cmark_markdown_to_html($0, Int(strlen($0)), options.rawValue) else {
throw MarkdownError.conversionFailed
}

Expand Down

0 comments on commit 09c0832

Please sign in to comment.