Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-59753

ScopeGuard is missing a deduction guide

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.1.0-rc0
    • Component/s: None
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible
    • Sprint:
      Service Arch 2021-09-20

      Description

      We don't need makeGuard anymore.
      The constructor set for ScopeGuard isn't quite compatible with CTAD so we need to give it a little push in the right direction.

      template <typename F>
      ScopeGuard(F&&) -> ScopeGuard<std::decay_t<F>>;
      

      This would enable simpler initializer syntax for ScopeGuard objects.

      (forked from SERVER-53021)

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              billy.donahue Billy Donahue
              Reporter:
              billy.donahue Billy Donahue
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: