[PATCH] D76289: [NFC][Attr TableGen] Emit Spelling Enum for Attr types if there >1
Erich Keane via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Mar 17 10:44:18 PDT 2020
erichkeane marked 3 inline comments as done.
erichkeane added inline comments.
================
Comment at: clang/utils/TableGen/ClangAttrEmitter.cpp:2333
- if (!ElideSpelling)
- SpellingEnum = CreateSemanticSpellings(Spellings, SemanticToSyntacticMap);
- if (Header)
----------------
rnk wrote:
> I had to call this function during both header and cpp file generation because some code later used the `SemanticToSyntacticMap` it fills in.
Ah! I didn't see anywhere that SpellingEnum was created. Perhaps thats my issue.
================
Comment at: clang/utils/TableGen/ClangAttrEmitter.cpp:2534
if (!ElideSpelling) {
assert(!SemanticToSyntacticMap.empty() && "Empty semantic mapping list");
if (Header)
----------------
rnk wrote:
> Won't this assert? I think we come here even if !Header.
I haven't got any asserts here, but I'm having weird problems from tablegen not getting recreated. I'll put the run-in-both-cases code back which should fix this anyway. New patch incoming as soon as it passes LIT.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D76289/new/
https://reviews.llvm.org/D76289
More information about the cfe-commits
mailing list