Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-09-28 Thread Aleksei Sidorin via cfe-commits
a.sidorin added a comment. Committed after Aaron's comment were addressed. Big thanks to all reviewers! Repository: rL LLVM https://reviews.llvm.org/D14326 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mail

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-09-28 Thread Aleksei Sidorin via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL282572: [ASTImporter] Implement some expression-related AST node import (part 2) (authored by a.sidorin). Changed prior to commit: https://reviews.llvm.org/D14326?vs=72625&id=72791#toc Repository: rL

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-09-27 Thread Aaron Ballman via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. LGTM with two minor nits. Comment at: lib/AST/ASTImporter.cpp:5563-5564 @@ +5562,4 @@ +const TemplateArgumentLoc *FromArgArray = E->getTemplateArgs(); +for (unsigned i = 0, e = E->getNumTemplateArgs();

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-09-27 Thread Aleksei Sidorin via cfe-commits
a.sidorin updated this revision to Diff 72625. a.sidorin added a comment. Address review comments; add accidentally missed file. https://reviews.llvm.org/D14326 Files: include/clang/AST/ASTImporter.h include/clang/AST/DeclFriend.h lib/AST/ASTImporter.cpp lib/Serialization/ASTReaderStmt.

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-09-27 Thread Alexey Bataev via cfe-commits
ABataev added inline comments. Comment at: lib/AST/ASTImporter.cpp:3414 @@ +3413,3 @@ + // FriendDecl is not a NamedDecl so we cannot use localUncachedLookup. + CXXRecordDecl *RD = cast(DC); + FriendDecl *ImportedFriend = RD->getFirstFriend(); CXXRecordDecl *RD

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-09-27 Thread Aleksei Sidorin via cfe-commits
a.sidorin updated the summary for this revision. a.sidorin added reviewers: ABataev, aaron.ballman. a.sidorin updated this revision to Diff 72614. a.sidorin added a comment. Merge patch https://reviews.llvm.org/D24807 to both fix segmentation fault and provide a test for it. https://reviews.llv

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-09-24 Thread Aleksei Sidorin via cfe-commits
a.sidorin added a comment. Don't hurry. The segfault is fixed already and patch waits for approval: https://reviews.llvm.org/D24807. I'll update this fix in Monday. https://reviews.llvm.org/D14326 ___ cfe-commits mailing list cfe-commits@lists.llvm

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-09-23 Thread Kareem Khazem via cfe-commits
khazem added a comment. I'm updating this patch so that it rebases cleanly onto master, as this patch hasn't been updated for a couple of months... At the time of writing, one of Clang's tests is failing with this patch. Specifically, there is a segfault at line 130 of test/ASTMerge/Inputs/exp

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-08-23 Thread Sean Callanan via cfe-commits
spyffe accepted this revision. spyffe added a comment. This revision is now accepted and ready to land. Yes, I look forward to testing this in LLDB. Thanks for your hard work. https://reviews.llvm.org/D14326 ___ cfe-commits mailing list cfe-commits

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-08-23 Thread Serge Pavlov via cfe-commits
sepavloff accepted this revision. sepavloff added a comment. LGTM. https://reviews.llvm.org/D14326 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-08-23 Thread Aleksei Sidorin via cfe-commits
a.sidorin added a comment. Serge, Sean, is this patch OK to commit? https://reviews.llvm.org/D14326 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-07-20 Thread Aleksei Sidorin via cfe-commits
a.sidorin updated this revision to Diff 64704. a.sidorin added a comment. Fix signed/unsigned mismatch warning in the loop condition. https://reviews.llvm.org/D14326 Files: include/clang/AST/ASTImporter.h include/clang/AST/DeclFriend.h lib/AST/ASTImporter.cpp test/ASTMerge/Inputs/class3

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-07-20 Thread Serge Pavlov via cfe-commits
sepavloff added a comment. With this patch unit tests pass on Windows as well. I do not have formal authority to approve patches, but for me the patch is good enough to be accepted. Comment at: lib/AST/ASTImporter.cpp:3422 @@ +3421,3 @@ + D->getTrailingObjects(); + for (i

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-07-20 Thread Aleksei Sidorin via cfe-commits
a.sidorin updated this revision to Diff 64676. a.sidorin added a comment. Removed unneeded matcher. https://reviews.llvm.org/D14326 Files: include/clang/AST/ASTImporter.h include/clang/AST/DeclFriend.h lib/AST/ASTImporter.cpp test/ASTMerge/Inputs/class3.cpp test/ASTMerge/Inputs/exprs3

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-07-20 Thread Aleksei Sidorin via cfe-commits
a.sidorin updated this revision to Diff 64663. a.sidorin added a comment. An attempt to fix unit test on Windows. Serge, thank you! Could you please check this patch again? https://reviews.llvm.org/D14326 Files: include/clang/AST/ASTImporter.h include/clang/AST/DeclFriend.h lib/AST/ASTImp

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-07-19 Thread Serge Pavlov via cfe-commits
Unit test ImportVAArgExpr fails on Windows. The source file: void declToImport(__builtin_va_list list, ...) { (void)__builtin_va_arg(list, int); } When compiled on Windows it produces AST: TranslationUnitDecl 0x638f150 <> `-FunctionDecl 0x638f780 line:1:6 declToImport 'void (__builtin

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-07-18 Thread Aleksei Sidorin via cfe-commits
a.sidorin added a comment. > I don't think this small improvement in Importer is worth invasive changes in > other components. Thanks, Serge. Is it OK to commit? https://reviews.llvm.org/D14326 ___ cfe-commits mailing list cfe-commits@lists.llvm.

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-07-09 Thread Serge Pavlov via cfe-commits
2016-07-01 15:26 GMT+06:00 Aleksei Sidorin : > a.sidorin updated this revision to Diff 62474. > a.sidorin added a comment. > > Fix some issues pointed by Serge Pavlov. > Serge: putting a check of FriendDecls to `IsStructurallyEquivalent()` > seems like a good idea for me, but we need some addition

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-07-01 Thread Aleksei Sidorin via cfe-commits
a.sidorin updated this revision to Diff 62474. a.sidorin added a comment. Fix some issues pointed by Serge Pavlov. Serge: putting a check of FriendDecls to `IsStructurallyEquivalent()` seems like a good idea for me, but we need some additional changes for it. `CXXRecodeDecl::getFirstDecl()` is

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-07-01 Thread Aleksei Sidorin via cfe-commits
a.sidorin marked 2 inline comments as done. Comment at: lib/AST/ASTImporter.cpp:3363 @@ +3362,3 @@ + + // Determine whether we've already imported this decl. + // FriendDecl is not a NamedDecl so we cannot use localUncachedLookup. a.sidorin wrote: > sepavloff wr

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-07-01 Thread Aleksei Sidorin via cfe-commits
a.sidorin marked 5 inline comments as done. a.sidorin added a comment. Thank you for your comments! And sorry for late response after pinging. Comment at: lib/AST/ASTImporter.cpp:2518-2519 @@ +2517,4 @@ +Importer.Import(D->getMessage())); + if (!Message) +return nul

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-06-01 Thread Serge Pavlov via cfe-commits
sepavloff added inline comments. Comment at: lib/AST/ASTImporter.cpp:2373 @@ +2372,3 @@ + Error = true; +ToInfo = TemplateArgumentLocInfo(TSI); + } else { Maybe `else` before this statement so that in the case of error `ToInfo` remained default initiali

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-05-31 Thread Aleksei Sidorin via cfe-commits
a.sidorin added a comment. Ping? http://reviews.llvm.org/D14326 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-05-19 Thread Aleksei Sidorin via cfe-commits
a.sidorin updated this revision to Diff 57796. a.sidorin marked an inline comment as done. a.sidorin added a comment. Add some basic tests for ExpressionTraitExpr and ArrayTypeTraitExpr. http://reviews.llvm.org/D14326 Files: include/clang/AST/ASTImporter.h include/clang/AST/DeclFriend.h l

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-05-11 Thread Aleksei Sidorin via cfe-commits
a.sidorin marked 4 inline comments as done. Comment at: lib/AST/ASTImporter.cpp:5527 @@ -5353,3 +5526,3 @@ FoundD, - /*FIXME:TemplateArgs=*/nullptr); + /*Templ

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-05-11 Thread Aleksei Sidorin via cfe-commits
a.sidorin updated this revision to Diff 56860. a.sidorin added a comment. Add error checks; replace `NULL` with `nullptr`. http://reviews.llvm.org/D14326 Files: include/clang/AST/ASTImporter.h include/clang/AST/DeclFriend.h lib/AST/ASTImporter.cpp test/ASTMerge/Inputs/class3.cpp test/

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-05-10 Thread Sean Callanan via cfe-commits
spyffe requested changes to this revision. spyffe added a comment. This revision now requires changes to proceed. Overall I'm very enthusiastic about this and only have a few nitpicks. Thanks for the hard work! Comment at: lib/AST/ASTImporter.cpp:2364 @@ +2363,3 @@ + if (Arg.

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-05-10 Thread Aleksei Sidorin via cfe-commits
a.sidorin marked 7 inline comments as done. Comment at: lib/AST/ASTImporter.cpp:5859 @@ +5858,3 @@ + Expr *ToQueried = Importer.Import(E->getQueriedExpression()); + if (!ToQueried) +return nullptr; I usually prefer allocation with required size at the start

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2016-05-10 Thread Aleksei Sidorin via cfe-commits
a.sidorin updated the summary for this revision. a.sidorin added a reviewer: spyffe. a.sidorin removed rL LLVM as the repository for this revision. a.sidorin updated this revision to Diff 56682. a.sidorin added a comment. - Some code cleanup - Add tests not present in http://reviews.llvm.org/D1428

Re: [PATCH] D14326: ASTImporter: expressions, pt.2

2015-11-09 Thread Serge Pavlov via cfe-commits
sepavloff added a comment. The patch requires tests. For instance, import of CXXBaseSpecifier can be tested along with static_cast: if a class indeed is a base, static_cast will be processed silent, otherwise a message must appear. ArraySubscript could be tested using constexpr function. Materi

[PATCH] D14326: ASTImporter: expressions, pt.2

2015-11-04 Thread Aleksei Sidorin via cfe-commits
a.sidorin created this revision. a.sidorin added a reviewer: sepavloff. a.sidorin added a subscriber: cfe-commits. a.sidorin set the repository for this revision to rL LLVM. This patch implements some expression-related AST node import (patch #2). Supported nodes: ArrayTypeTraitExpr ExpressionTra