HasLateBinding returns true if the function has late bindings. A function cannot mix late bindings with other bindings.
()
| 314 | |
| 315 | // HasLateBinding returns true if the function has late bindings. A function cannot mix late bindings with other bindings. |
| 316 | func (f *FunctionDecl) HasLateBinding() bool { |
| 317 | if f == nil { |
| 318 | return false |
| 319 | } |
| 320 | if f.singleton != nil && f.singleton.Async != nil { |
| 321 | return true |
| 322 | } |
| 323 | for _, oID := range f.overloadOrdinals { |
| 324 | o := f.overloads[oID] |
| 325 | if o.HasLateBinding() { |
| 326 | return true |
| 327 | } |
| 328 | } |
| 329 | return false |
| 330 | } |
| 331 | |
| 332 | // Bindings produces a set of function bindings, if any are defined. |
| 333 | func (f *FunctionDecl) Bindings() ([]*functions.Overload, error) { |
no outgoing calls