]> git.proxmox.com Git - cargo.git/commitdiff
Make leak function private
authorest31 <MTest31@outlook.com>
Fri, 26 Jun 2020 17:51:47 +0000 (19:51 +0200)
committerest31 <MTest31@outlook.com>
Fri, 26 Jun 2020 17:55:29 +0000 (19:55 +0200)
The leak function is never used outside of interning.rs
and I don't think it makes any sense to use it.

src/cargo/util/interning.rs

index 942869ac70b8e624f45af9f78afbcc6007447446..bbec12942696378af216bc493f1f4c95892df50d 100644 (file)
@@ -11,7 +11,7 @@ use std::ptr;
 use std::str;
 use std::sync::Mutex;
 
-pub fn leak(s: String) -> &'static str {
+fn leak(s: String) -> &'static str {
     Box::leak(s.into_boxed_str())
 }