[PATCH] D56581: [ASTImporter] Set the described template if not set

2019-01-31 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment.

> @martong have you had a chance to look at this some more? We ran into another 
> problem that this fixes partially.

I didn't have time to deal with this yet (these days we are preparing an 
internal release and that took away my time).

> Can I help in any way?

I think the only thing missing is to have a test. You mentioned previously that 
you could help with that and I would appreciate all your help. I think a test 
with `clang-import-test` would be just great.


Repository:
  rC Clang

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

https://reviews.llvm.org/D56581



___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D56581: [ASTImporter] Set the described template if not set

2019-01-30 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment.

@martong have you had a chance to look at this some more? We ran into another 
problem that this fixes partially. Can I help in any way?


Repository:
  rC Clang

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

https://reviews.llvm.org/D56581



___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D56581: [ASTImporter] Set the described template if not set

2019-01-25 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a subscriber: aprantl.
shafik added a comment.

I don't believe it is directly related to modules but that it just triggers the 
issue because it may be bringing in more. You can find a description here 
https://clang.llvm.org/docs/CommandGuide/clang.html#cmdoption-g and @aprantl 
pointed me to this talk if you want to even more 
http://llvm.org/devmtg/2015-10/#talk19


Repository:
  rC Clang

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

https://reviews.llvm.org/D56581



___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D56581: [ASTImporter] Set the described template if not set

2019-01-25 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment.

@shafik Ok, I'll take a look into the regression soon. What are exactly 
gmodules? Is it macOS only? Do you have a description or some docs about it?


Repository:
  rC Clang

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

https://reviews.llvm.org/D56581



___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D56581: [ASTImporter] Set the described template if not set

2019-01-24 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment.

@martong Unfortunately this causes a regression on one of the lldb tests 
`TestDataFormatterLibcxxVector.py` e.g.

  lldb-dotest -p TestDataFormatterLibcxxVector.py -t -G gmodules 
--no-multiprocess 

So this is specific to modules. If you can't reproduce this I can provide a 
back-trace.


Repository:
  rC Clang

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

https://reviews.llvm.org/D56581



___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D56581: [ASTImporter] Set the described template if not set

2019-01-12 Thread Aleksei Sidorin via Phabricator via cfe-commits
a_sidorin added a comment.

Hello Gabor,

This looks good, but as Shafik mentioned, adding a test would be nice.


Repository:
  rC Clang

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

https://reviews.llvm.org/D56581



___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D56581: [ASTImporter] Set the described template if not set

2019-01-11 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment.

Can you add a test?


Repository:
  rC Clang

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

https://reviews.llvm.org/D56581



___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D56581: [ASTImporter] Set the described template if not set

2019-01-11 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision.
martong added reviewers: shafik, a_sidorin.
Herald added subscribers: cfe-commits, gamesh411, Szelethus, dkrupp, rnkovacs.
Herald added a reviewer: a.sidorin.

During the addition of an injected class type to a record it may happen
that a CXXRecordDecl in the redecl chain does not have a described
template set and this caused an assert in LLDB.


Repository:
  rC Clang

https://reviews.llvm.org/D56581

Files:
  lib/AST/ASTImporter.cpp


Index: lib/AST/ASTImporter.cpp
===
--- lib/AST/ASTImporter.cpp
+++ lib/AST/ASTImporter.cpp
@@ -2734,6 +2734,9 @@
 getCanonicalForwardRedeclChain(D2CXX);
 for (auto *R : Redecls) {
   auto *RI = cast(R);
+  // Existing Decl in the chain might not have the described
+  // template set, so we set it now.
+  RI->setDescribedClassTemplate(ToDescribed);
   RI->setTypeForDecl(nullptr);
   // Below we create a new injected type and assign that to the
   // canonical decl, subsequent declarations in the chain will reuse


Index: lib/AST/ASTImporter.cpp
===
--- lib/AST/ASTImporter.cpp
+++ lib/AST/ASTImporter.cpp
@@ -2734,6 +2734,9 @@
 getCanonicalForwardRedeclChain(D2CXX);
 for (auto *R : Redecls) {
   auto *RI = cast(R);
+  // Existing Decl in the chain might not have the described
+  // template set, so we set it now.
+  RI->setDescribedClassTemplate(ToDescribed);
   RI->setTypeForDecl(nullptr);
   // Below we create a new injected type and assign that to the
   // canonical decl, subsequent declarations in the chain will reuse
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits