mirror of
https://github.com/boostorg/core.git
synced 2025-11-29 22:00:17 +01:00
Moved checked deleters into internal namespace to block unintended ADL.
This prevents adding namespace boost to ADL when the deleters are used in template parameters, e.g. in std::unique_ptr.
This commit is contained in:
@@ -11,9 +11,9 @@
|
||||
|
||||
* Added a new [link core.functor `boost/core/functor.hpp`] header with a `functor` class template
|
||||
for wrapping a raw function into a function object class.
|
||||
* Changed [link core.null_deleter `null_deleter`] and [link core.fclose_deleter `fclose_deleter`]
|
||||
definitions so that they don't bring namespace `boost` into argument-dependent lookup in cases
|
||||
like this:
|
||||
* Changed [link core.null_deleter `null_deleter`], [link core.fclose_deleter `fclose_deleter`]
|
||||
and [link.checked_delete checked deleter] definitions so that they don't bring namespace `boost`
|
||||
into argument-dependent lookup in cases like this:
|
||||
```
|
||||
std::unique_ptr< std::FILE, boost::fclose_deleter > p1, p2;
|
||||
swap(p1, p2); // no longer looks for boost::swap as part of ADL
|
||||
|
||||
Reference in New Issue
Block a user