================
Comment at: lib/AST/MicrosoftMangle.cpp:615
@@ +614,3 @@
+    size_t Size = NameBackReferences.size();
+    BackRefMap::MapEntryTy &Entry =
+        NameBackReferences.GetOrCreateValue(Name, Size);
----------------
Timur Iskhodzhanov wrote:
> You probably want
> 
>   std::tie(I, Inserted) = NameBackReferences.insert(...)
> 
> See `MicrosoftCXXABI::getAddrOfVTable` as an example.
Indeed, the standard `insert` interface is what I would want. However, 
`StringMap` does not offer this interface, its `insert` member simply returns 
`bool`.

================
Comment at: lib/AST/MicrosoftMangle.cpp:694
@@ -673,1 +693,3 @@
+    llvm::SmallString<64> TemplateMangling;
+    llvm::raw_svector_ostream Stream(TemplateMangling);
     MicrosoftCXXNameMangler Extra(Context, Stream);
----------------
Timur Iskhodzhanov wrote:
> Am I right that you need `raw_svector_ostream` just to use `SmallString` 
> instead of `string`?
That is correct.

http://reviews.llvm.org/D4130



_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to