Fix to use IterAdapter with generic "position" types
seemingly the operator-> was not yet used in any real scenario. The whole point with IterAdapter is that it uses an opaque "location type", which is owned by the controlling container. In many cases this will actually be just a pointer into the container storage, but we must not assume it is this way. Thus the only way to obtain a (language) pointer is to dereference the "position type" and take the address of the result
This commit is contained in:
parent
0d10e62851
commit
82ef5964ba
1 changed files with 1 additions and 1 deletions
|
|
@ -193,7 +193,7 @@ namespace lib {
|
|||
operator->() const
|
||||
{
|
||||
_maybe_throw();
|
||||
return pos_;
|
||||
return & *pos_;
|
||||
}
|
||||
|
||||
IterAdapter&
|
||||
|
|
|
|||
Loading…
Reference in a new issue