This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Supporting non-standard pointer types in STL containers


a quick feedback: any possible change in this area will go in mainline only. Thus, in order to allow the maintainers to further investigate this work, please provide the changes to stl_tree.h in in the form of a diff vs current mainline.

I'm posting a patch for stl_tree.h which shows the code changes needed to support alternative pointer types. I've confirmed using the testsuite that this set of changes created no new errors when run with normal pointer types. The changes in this case included some work to preserve ABI compatibility with code compiled in previous versions of libstdc++-v3.


To test this with an alternative pointer implementation, I wrote and used a relative_ptr<>, to confirm a case where a non-standard pointer could work. My testing with this pointer hasn't been as exhaustive as the regular testsuite. This alternative pointer doesn't need to become part of libstdc++, but could be added to ext/ or to the test suite as an example.

A pdf on google docs explains the design, and will be shared out to this list.

Again, I appreciate any time spent looking this over, and any suggestions, bug reports, etc.
Thanks,


- Bob Walters

Attachment: patch_stl_tree_h.txt
Description: Text document

Attachment: cast.h
Description: Binary data




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]