Skip to main content

Questions tagged [dynamic-dispatch]

For questions about determining the code to execute for a function or method call with multiple candidates at run time, using one or more argument values or the method receiver

Filter by
Sorted by
Tagged with
3 votes
1 answer

Declaration-site vs use-site overloading

By overloading, I mean allowing multiple type members that seem to conceptually do the same thing to use the same name, but possibly with different representations of the inputs. ...
Mike Samuel's user avatar
2 votes
1 answer

Virtual functions from two classes

Years ago, I have implemented something in C++ that involves two kinds of list of the same value type: a sparse list and a dense list. Each operation between two lists has 4 versions (two of them are ...
user23013's user avatar
  • 2,510
8 votes
2 answers

How to dynamically dispatch extension methods?

Swift allows you to define extension methods on any type or protocol. While extension methods on protocols are frequently used to provide default implementations, only methods listed in the main ...
Bbrk24's user avatar
  • 9,067
10 votes
1 answer

Static or dynamic dispatch for parametric polymorphism

I read that, in GHC: Type classes are implemented using a type-directed implicit parameter-passing mechanism. Each constraint on a type is treated as a parameter containing a dictionary of the ...
pxeger's user avatar
  • 848