if C++ had rank-2 polymorphism, would it wear it like this (C++ functors / funct...

@joomy@functional.cafe

if C++ had rank-2 polymorphism, would it wear it

  • like this (C++ functors / function objects: a struct with operator())
  • or like this (arguments with the higher-order polymorphic type will be typed std::any instead)