diff options
author | David Tolnay <dtolnay@gmail.com> | 2023-09-03 12:14:45 -0700 |
---|---|---|
committer | David Tolnay <dtolnay@gmail.com> | 2023-09-03 12:41:41 -0700 |
commit | 927d8ead12bc08d381b4edefef3227d1fc7c67b8 (patch) | |
tree | aef333819773a4651ff11cd9603c72f87aa5c73e /gen/build/src/intern.rs | |
parent | c06cb140e6bb64f9bac2cca634cafc90508f7429 (diff) | |
download | cxx-927d8ead12bc08d381b4edefef3227d1fc7c67b8.tar.gz |
Reduce visibility of all pub items which are not publicly exported
Diffstat (limited to 'gen/build/src/intern.rs')
-rw-r--r-- | gen/build/src/intern.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gen/build/src/intern.rs b/gen/build/src/intern.rs index c8b57d89..753e3f31 100644 --- a/gen/build/src/intern.rs +++ b/gen/build/src/intern.rs @@ -3,15 +3,15 @@ use once_cell::sync::OnceCell; use std::sync::{Mutex, PoisonError}; #[derive(Copy, Clone, Default)] -pub struct InternedString(&'static str); +pub(crate) struct InternedString(&'static str); impl InternedString { - pub fn str(self) -> &'static str { + pub(crate) fn str(self) -> &'static str { self.0 } } -pub fn intern(s: &str) -> InternedString { +pub(crate) fn intern(s: &str) -> InternedString { static INTERN: OnceCell<Mutex<Set<&'static str>>> = OnceCell::new(); let mut set = INTERN |