lin2k / pdfium

Automatically exported from code.google.com/p/pdfium
0 stars 0 forks source link

CFX_ByteStringC, CFX_WideStringC and friends don't interoperate with std::map Container. #142

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
In fact, they silently do the wrong thing.

1.  There's no operator< for these classes to provide an ordering.
2.  They have implicit cast operators that promote to pointer types.

So I think you wind up with a map ordered by the address of the string storage, 
not the contents itself.

Original issue reported on code.google.com by tsepez@chromium.org on 21 Apr 2015 at 6:39

GoogleCodeExporter commented 9 years ago

Original comment by tsepez@chromium.org on 21 Apr 2015 at 6:40

GoogleCodeExporter commented 9 years ago
https://pdfium.googlesource.com/pdfium/+/ca19b6e6b4e81ba0fce1bc9d2e145cb39cf0537
d

Original comment by tsepez@chromium.org on 22 Apr 2015 at 5:10

GoogleCodeExporter commented 9 years ago
https://pdfium.googlesource.com/pdfium/+/ea6a069e6e593d97513e86fc761cf789a9714c2
2

Original comment by tsepez@chromium.org on 22 Apr 2015 at 5:23

GoogleCodeExporter commented 9 years ago
https://pdfium.googlesource.com/pdfium/+/1ddf056da74de0a34631b8a719f4f02b4ec8214
4

Original comment by tsepez@chromium.org on 22 Apr 2015 at 7:09

GoogleCodeExporter commented 9 years ago
https://pdfium.googlesource.com/pdfium/+/fbfcbc5e82d89585a63a77c63e782fb6768c8dc
8

Original comment by tsepez@chromium.org on 22 Apr 2015 at 7:16

GoogleCodeExporter commented 9 years ago

Original comment by tsepez@chromium.org on 22 Apr 2015 at 7:23