Skip to content

Commit

Permalink
Remove unnecessary conditional branch
Browse files Browse the repository at this point in the history
  • Loading branch information
TristonianJones committed Jun 10, 2024
1 parent 3644294 commit b3c8386
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion common/decls/decls.go
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ func (f *FunctionDecl) AddOverload(overload *OverloadDecl) error {
if oID == overload.ID() {
if o.SignatureEquals(overload) && o.IsNonStrict() == overload.IsNonStrict() {
// Allow redefinition of an overload implementation so long as the signatures match.
if !o.hasBinding() || overload.hasBinding() {
if overload.hasBinding() {
f.overloads[oID] = overload
}
return nil
Expand Down

0 comments on commit b3c8386

Please sign in to comment.