[llvm] 78f543e - [NFC] Use std::free instead of ::free

Louis Dionne via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 20 13:19:18 PDT 2020


Author: Louis Dionne
Date: 2020-07-20T16:19:08-04:00
New Revision: 78f543e5a1cd46b5232d5479dd513d2110f52e96

URL: https://github.com/llvm/llvm-project/commit/78f543e5a1cd46b5232d5479dd513d2110f52e96
DIFF: https://github.com/llvm/llvm-project/commit/78f543e5a1cd46b5232d5479dd513d2110f52e96.diff

LOG: [NFC] Use std::free instead of ::free

Since we include <cstdlib> instead of <stdlib.h>, it makes sense to
use std::free.

Added: 
    

Modified: 
    llvm/lib/Demangle/Demangle.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Demangle/Demangle.cpp b/llvm/lib/Demangle/Demangle.cpp
index 71dafa0b2e43..000f75b6a977 100644
--- a/llvm/lib/Demangle/Demangle.cpp
+++ b/llvm/lib/Demangle/Demangle.cpp
@@ -31,6 +31,6 @@ std::string llvm::demangle(const std::string &MangledName) {
     return MangledName;
 
   std::string Ret = Demangled;
-  free(Demangled);
+  std::free(Demangled);
   return Ret;
 }


        


More information about the llvm-commits mailing list