[PATCH] D97411: [DebugInfo] Add an attribute to force type info to be emitted for types that are required to be complete.

Aaron Ballman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Feb 26 12:41:08 PST 2021


aaron.ballman added a comment.

Thanks! I am still curious about the forward declare/redeclaration behavior and whether that is a situation that makes sense or not. I suspect this case may make sense (and likely already works):

  // Should test redeclaration behavior.
  struct [[clang::standalone_debug]] redecl;
  struct redecl {};

but I'm not certain if this case makes sense:

  struct [[clang::standalone_debug]] S; // Does this make sense on forward declare that's never defined?



================
Comment at: clang/test/Sema/attr-standalonedebug.cpp:1-4
+// RUN: %clang_cc1 %s -verify -fsyntax-only -DCPP
+// RUN: %clang_cc1 %s -verify -fsyntax-only -x c
+
+#ifdef CPP
----------------



Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D97411



More information about the cfe-commits mailing list