• 🇨🇦 tunetardis@lemmy.ca
    link
    fedilink
    English
    arrow-up
    1
    ·
    3 年前

    Well the test3 example FTA gives a case where NRVO would not happen because of the conditional return value. Are you suggesting that you need not std::move even in this case?

    • gracicotOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      3 年前

      I would still say “no” since they are local objects and they are gonna be moved from implicitly anyway