mirror of
https://github.com/vimpunk/mio.git
synced 2025-12-06 08:46:51 +08:00
Merge pull request #5 from lukediamond/master
Fixed mutable begin() for basic_mmap.
This commit is contained in:
commit
b6ca040f1b
@ -151,7 +151,10 @@ public:
|
||||
* Returns an iterator to the first requested byte, if a valid memory mapping
|
||||
* exists, otherwise this function call is equivalent to invoking `end`.
|
||||
*/
|
||||
iterator begin() noexcept { return impl_.begin(); }
|
||||
template<
|
||||
access_mode A = AccessMode,
|
||||
typename = typename std::enable_if<A == access_mode::write>::type
|
||||
> iterator begin() noexcept { return impl_.begin(); }
|
||||
const_iterator begin() const noexcept { return impl_.begin(); }
|
||||
const_iterator cbegin() const noexcept { return impl_.cbegin(); }
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user