python-variants/variants

Add examples that are not about simply dispatching

Opened this issue · 0 comments

Right now all examples take the same number of arguments, return the same thing, etc. We should show some examples of:

  • Variants that take a different number of arguments from one another
  • Variants which return different things
  • A variant that suppresses a specific error maybe?
  • Variants for maintaining backwards compatibility
  • Caching and non-caching versions of a function
  • Asynchronous and blocking versions of a function