[all-commits] [llvm/llvm-project] 40ad66: [dllexport] odr-use constexpr default args for con...
Hans via All-commits
all-commits at lists.llvm.org
Mon Apr 11 07:25:07 PDT 2022
Author: Hans Wennborg <hans at chromium.org>
Date: 2022-04-11 (Mon, 11 Apr 2022)
[dllexport] odr-use constexpr default args for constructor closures
InstantiateDefaultCtorDefaultArgs() is supposed to mark default
constructor args as odr-used, since those args will be used when
emitting the constructor closure.
However, constexpr vars were not getting odr-used since
DoMarkVarDeclReferenced() defers them in MaybeODRUseExprs, and the code
was calling CleanupVarDeclMarking() which discarded those uses instead
of processing them.
(This came up in Chromium, crbug.com/1312086)
Differential revision: https://reviews.llvm.org/D123405
More information about the All-commits