r178548 - [ms-cxxabi] Move MS inheritance model calculation into MemberPointerType

Jordan Rose jordan_rose at apple.com
Tue Apr 2 09:28:53 PDT 2013


On Apr 2, 2013, at 9:23 , Reid Kleckner <reid at kleckner.net> wrote:

> +enum MSInheritanceModel {
> +  IHM_Single,
> +  IHM_Multiple,
> +  IHM_Virtual,
> +  IHM_Unspecified
> +};

This is /really/ bikeshedding, but what is "IHM"? "InHeritance Model"? I would have expected "MSIM" as the prefix here.

>     default: llvm_unreachable("unknown inheritance model");
> +    case IHM_Unspecified: ++Ints;  // VBTableOffset
> +    case IHM_Virtual:     ++Ints;  // VirtualBaseAdjustmentOffset
> +    case IHM_Multiple:    ++Ints;  // NonVirtualBaseAdjustment
> +    case IHM_Single:      break;   // Nothing

Now that the switch statement covers all the enum cases (because the enum changed), you should remove the "default" case; otherwise this will complain on some builders.

Sorry I didn't look at these in pre-commit.
Jordan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130402/3b51863a/attachment.html>


More information about the cfe-commits mailing list