Is there a more precise term than simply "casting"? "Casting" often includes for example integer -> float or pointer -> unrelated pointer; whereas I'm describing exclusively casting up or down the type hierarchy.

  • 1
    $\begingroup$ What's wrong with "upcasting" and "downcasting"? $\endgroup$ – Derek Elkins left SE Aug 28 '19 at 19:02
  • 1
    $\begingroup$ if you're writing a paper, you can simply define your own term $\endgroup$ – Zachary Hunter Aug 28 '19 at 20:26
  • $\begingroup$ I named a Rust trait that provided upcast and downcast methods "Cast" and wondered if there was a more appropriate name! $\endgroup$ – Max Aug 29 '19 at 9:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.