Modify

Opened 10 years ago

Last modified 5 years ago

#1947 new Patches

traversal access decoupling

Reported by: Roland Schwarz Owned by: jeffrey.hellrung
Milestone: Boost 1.36.0 Component: iterator
Version: Boost 1.35.0 Severity: Problem
Keywords: Cc: roland.schwarz@…

Description

In an attempt to use iterator_facade to implement a "Readable" and "Writeable"

"Swapable" "Random Access" iterator

I found that the expression: it[n] returns an object of type operator_brackets_proxy that is convert- ible to "reference" but not to "value_type".

Consequently I can use

value_type a; it[n] = a;

but not a = it[n];

I am not sure of how to correctly solve this issue. Here is a pointer to a discussion on the list:

http://lists.boost.org/Archives/boost/2008/05/137868.php

Attachments (2)

iterator_facade.diff (482 bytes) - added by Roland Schwarz 10 years ago.
boost-changes.diff (10.2 KB) - added by Dave Abrahams 8 years ago.

Download all attachments as: .zip

Change History (5)

Changed 10 years ago by Roland Schwarz

Attachment: iterator_facade.diff added

comment:1 Changed 10 years ago by Roland Schwarz

Type: Support RequestsPatches

A straight forward solution that considers Sebastian Redls concerns is to never return the Reference type.

Patch attached.

comment:2 Changed 8 years ago by Dave Abrahams

Owner: changed from Dave Abrahams to Thomas Witt

The hard part was making tests that would detect the absence of your fix. Unfortunately, I ran out of time to commit this and run it through the test/release-branch-merge cycle. My patch is attached. Reassigning to Thomas in hopes he has time for that.

Changed 8 years ago by Dave Abrahams

Attachment: boost-changes.diff added

comment:3 Changed 5 years ago by Dave Abrahams

Owner: changed from Thomas Witt to jeffrey.hellrung

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain jeffrey.hellrung.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.