Swift with objective-git: Overloads for 'createCommitWithTree' exist with these partially matching parameter lists <p>I am using objective-git with Swift and cannot compile the GTRepository.createCommitWithTree method.</p> <p>The method can optionally be called without author : GTSignature and committer : GTSignature parameters.</p> <p>I'm new to Swift and overloading functions. I'd like to know how to structure this so it will compile.</p> <p>My code uses all the types specified in the objective-git method:</p> <pre><code>func commitTree ( tree : GTTree ) { let message : NSString let author : GTSignature let committer : GTSignature let parents : NSArray let updatingReferenceNamed : NSString var error : NSError? GTRepository.createCommitWithTree( tree, message, author, committer, parents, updatingReferenceNamed, &amp;error ) } </code></pre> <p>In this code, compiler cannot invoke method with an argument list of these types. Compiler provides additional information: "Overloads for 'createCommitWithTree' exist with these partially matching parameter lists: (GTTree, message: String, author: GTSignature, committer: GTSignature, parents: [AnyObject]?, updatingReferenceNamed: String?), (GTTree, message: String, parents: [AnyObject]?, updatingReferenceNamed: String?)"</p> <p>If I refactor to use the types suggested above, compiler won't compile with "Ambiguous reference to member 'createCommitWithTree'"</p> <p>How do I write this to compile?</p> <p>Thanks</p>