MCPcopy Create free account
hub / github.com/cel-expr/cel-go / newOverload

Function newOverload

common/decls/decls.go:607–621  ·  view source on GitHub ↗
(overloadID string,
	memberFunction bool, args []*types.Type, resultType *types.Type,
	opts ...OverloadOpt)

Source from the content-addressed store, hash-verified

605}
606
607func newOverload(overloadID string,
608 memberFunction bool, args []*types.Type, resultType *types.Type,
609 opts ...OverloadOpt) FunctionOpt {
610 return func(f *FunctionDecl) (*FunctionDecl, error) {
611 overload, err := newOverloadInternal(overloadID, memberFunction, args, resultType, opts...)
612 if err != nil {
613 return nil, err
614 }
615 err = f.AddOverload(overload)
616 if err != nil {
617 return nil, err
618 }
619 return f, nil
620 }
621}
622
623func newOverloadInternal(overloadID string,
624 memberFunction bool, args []*types.Type, resultType *types.Type,

Callers 2

OverloadFunction · 0.85
MemberOverloadFunction · 0.85

Calls 2

newOverloadInternalFunction · 0.85
AddOverloadMethod · 0.45

Tested by

no test coverage detected