================
@@ -1287,6 +1287,44 @@ bool
ASTNodeImporter::hasSameVisibilityContextAndLinkage(TypedefNameDecl *Found,
using namespace clang;
+class ASTImporter::FunctionReturnTypeDeclCycleDetector {
+public:
+ class DeclCycleMapInserter {
----------------
ojhunt wrote:
I'm sorry, just the other day I finally found that we do have an existing
mechanism for scoped cleanup: `llvm::make_scope_exit`
It _might_ be cleaner to mostly restore your original cleanup code, but use
```cpp
llvm::make_scope_exit([&]() { ...erase(..); }
```
to handle the cleanup (sorry, I literally only found out about this function a
couple of days ago)
@shafik do you have an opinion on which path is better?
https://github.com/llvm/llvm-project/pull/162514
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits