std::chrono...,operator-=(3)

πŸ“¦ version 2024.07.05, in nixpkgs unstable, opensuse-leap 16.0

🌸 NAME 🌸

okay bestie, this page is called std::chrono...,operator-=(3) and it comes straight from the C++ Standard Libary manual πŸ’–. It's all about std::chrono::time_point::operator+= and std::chrono::time_point::operator-= β€” the little shortcuts that nudge a time point by a duration. no cap.

✨ Synopsis ✨

time_point& operator+=( const duration& d ); (1) (since C++11)
                                                           (constexpr since C++17)
time_point& operator-=( const duration& d ); (2) (since C++11)
                                                           (constexpr since C++17)

Modifies the time point by the given duration. obsessed.

  1. Applies the offset d to pt. Effectively, d is added to the internally stored duration d_ as d_ += d.
  2. Applies the offset d to pt in negative direction. Effectively, d is subtracted from the internally stored duration d_ as d_ -= d.

πŸ’– Parameters πŸ’–

  • d β€” a time offset to apply

🫢 Return value 🫢

  • *this β€” periodt, that's what comes back.

😭 Exceptions 😭

  • May throw implementation-defined exceptions. yes, dramatic but true.

πŸŽ€ Example πŸŽ€

This section is incomplete Reason: no example

πŸ¦‹ See also πŸ¦‹

  • operator+ performs add and subtract operations involving a time point
  • operator- (function template) (C++11)

🌈 Category 🌈

  • Category: Todo no example

mwah πŸ’‹ β€” this iconic little page came from cppreference.com, dated 2024.06.10, and its page name is std::chrono...,operator-=(3). πŸ’…βœ¨

πŸ“¦ where this page comes from