Explorar el Código

All no longer specified factory functions removed (fixes #89).

main
offa hace 7 años
padre
commit
31ed32a066
Se han modificado 4 ficheros con 0 adiciones y 41 borrados
  1. +0
    -8
      include/scope_exit.h
  2. +0
    -8
      include/scope_fail.h
  3. +0
    -8
      include/scope_success.h
  4. +0
    -17
      include/unique_resource.h

+ 0
- 8
include/scope_exit.h Ver fichero

@@ -55,13 +55,5 @@ namespace sr
template<class EF>
scope_exit(EF&& ef) -> scope_exit<std::decay_t<EF>>;


template<class EF>
[[deprecated("Use ctor instead. Will be removed in a future v0.2.x release")]]
scope_exit<std::decay_t<EF>> make_scope_exit(EF&& exitFunction)
{
return scope_exit{std::forward<EF>(exitFunction)};
}

}


+ 0
- 8
include/scope_fail.h Ver fichero

@@ -65,13 +65,5 @@ namespace sr
template<class EF>
scope_fail(EF&& ef) -> scope_fail<std::decay_t<EF>>;


template<class EF>
[[deprecated("Use ctor instead. Will be removed in a future v0.2.x release")]]
scope_fail<std::decay_t<EF>> make_scope_fail(EF&& exitFunction)
{
return scope_fail{std::forward<EF>(exitFunction)};
}

}


+ 0
- 8
include/scope_success.h Ver fichero

@@ -58,13 +58,5 @@ namespace sr
template<class EF>
scope_success(EF&& ef) -> scope_success<std::decay_t<EF>>;


template<class EF>
[[deprecated("Use ctor instead. Will be removed in a future v0.2.x release")]]
scope_success<std::decay_t<EF>> make_scope_success(EF&& exitFunction)
{
return scope_success{std::forward<EF>(exitFunction)};
}

}


+ 0
- 17
include/unique_resource.h Ver fichero

@@ -207,23 +207,6 @@ namespace sr
unique_resource(std::reference_wrapper<R> r, D&& d) -> unique_resource<R&, std::decay_t<D>>;


template<class R, class D>
[[deprecated("Use ctor instead. Will be removed in a future v0.2.x release")]]
unique_resource<std::decay_t<R>, std::decay_t<D>> make_unique_resource(R&& r, D&& d)
noexcept(std::is_nothrow_constructible_v<std::decay_t<R>, R>
&& std::is_nothrow_constructible_v<std::decay_t<D>, D>)
{
return unique_resource{std::forward<R>(r), std::forward<D>(d)};
}

template<class R, class D>
[[deprecated("Use ctor instead. Will be removed in a future v0.2.x release")]]
unique_resource<R&, std::decay_t<D>> make_unique_resource(std::reference_wrapper<R> r, D d)
noexcept(std::is_nothrow_constructible_v<std::decay_t<D>, D>)
{
return unique_resource{r.get(), std::forward<D>(d)};
}

template<class R, class D, class S = R>
unique_resource<std::decay_t<R>, std::decay_t<D>> make_unique_resource_checked(R&& r, const S& invalid, D&& d)
noexcept(std::is_nothrow_constructible_v<std::decay_t<R>, R>

Cargando…
Cancelar
Guardar