[cfe-dev] Patch & feedback request
Erik Verbruggen
erikjv at me.com
Mon Jul 27 06:14:59 PDT 2009
On Monday, 27 July, 2009, at 01:16PM, "Sebastian Redl" <sebastian.redl at getdesigned.at> wrote:
>I believe, from previous reviews I've seen, that an operator < should only
>be defined if there is a natural ordering. If you simply need an ordering
>for a std::map (which you may want to replace by one of LLVM's own ADTs, by
>the way - another point that comes up often, though it depends on what you
>do with the map), it is, I believe, generally preferred to write a custom
>ordering predicate and supply it as a template parameter.
A new patch is attached, which:
- has a custom ordering predecate for QualType
- fixes a range bug (where the last handler wasn't checked)
- fixes a crash when the caught exception type is null (i.e. for catch(...))
- adds a testcase
On the map type: I checked http://llvm.org/docs/ProgrammersManual.html#ds_map and none of the other datatypes seem applicable.
Erik.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: unreachable-exception-handlers.patch
Type: application/octet-stream
Size: 3401 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20090727/aeb8be1d/attachment.obj>
More information about the cfe-dev
mailing list