1 Matching Annotations
  1. Apr 2022
    1. First, r-value references extend the lifespan of the object they are initialized with to the lifespan of the r-value reference (l-value references to const objects can do this too). Second, non-const r-value references allow you to modify the r-value!

      R-value references 有什么性质非常有用?