Skip to content

Commit

Permalink
Fix warning from extra try
Browse files Browse the repository at this point in the history
  • Loading branch information
tristanlabelle committed Nov 23, 2024
1 parent d3d8a40 commit 7636e6b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Sources/DotNetMetadata/Assembly+resolve.swift
Original file line number Diff line number Diff line change
Expand Up @@ -174,12 +174,12 @@ extension Assembly {
paramTypes: sig.params.map { try resolveTypeSig($0.type) })
guard let method else { return nil }

func matches(_ param: ParamBase, _ paramSig: ParamSig) throws -> Bool {
func matches(_ param: ParamBase, _ paramSig: ParamSig) -> Bool {
// TODO: Compare CustomMods
try param.isByRef == paramSig.byRef && param.type == resolveTypeSig(paramSig.type)
param.isByRef == paramSig.byRef && param.type == resolveTypeSig(paramSig.type)
}

guard (try? matches(method.returnParam, sig.returnParam)) == true else { return nil }
guard matches(method.returnParam, sig.returnParam) else { return nil }

// TODO: Compare param byrefs and custom mods
return method
Expand Down

0 comments on commit 7636e6b

Please sign in to comment.