[PATCH] D136554: Implement CWG2631

Jordan Rupprecht via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Dec 15 21:09:32 PST 2022


rupprecht added a comment.

I applied this version of the patch and the crash is now gone 🎉

However, now I get this inexplicable error -- I'm not entirely sure it's related, maybe I'm holding it wrong:

  In module '<foo>':
  foo.h$line:$num: error: 'foo::FooClass' has different definitions in different modules; first difference is definition in module 'something.h' found data member 'kFooDelimiter' with an initializer
    static constexpr char kFooDelimiter = '+';
    ~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
  foo.h:$line:$num note: but in 'other.h' found data member 'kFooDelimiter' with a different initializer
    static constexpr char kFooDelimiter = '+';
    ~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~

The definition seems straightforward:

  class FooClass final {
    ...
    static constexpr char kFooDelimiter = '+';
    ...
  };


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D136554/new/

https://reviews.llvm.org/D136554



More information about the cfe-commits mailing list