Skip to content

Commit def5a1d

Browse files
committed
unreachable-pub
1 parent bc5823d commit def5a1d

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

crates/salsa/salsa-macros/src/parenthesized.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
pub(crate) struct Parenthesized<T>(pub T);
1+
pub(crate) struct Parenthesized<T>(pub(crate) T);
22

33
impl<T> syn::parse::Parse for Parenthesized<T>
44
where

crates/salsa/src/lru.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ where
6262
Node: LruNode,
6363
{
6464
/// Creates a new LRU list where LRU caching is disabled.
65-
pub fn new() -> Self {
65+
pub(crate) fn new() -> Self {
6666
Self::with_seed(LRU_SEED)
6767
}
6868

@@ -73,7 +73,7 @@ where
7373

7474
/// Adjust the total number of nodes permitted to have a value at
7575
/// once. If `len` is zero, this disables LRU caching completely.
76-
pub fn set_lru_capacity(&self, len: usize) {
76+
pub(crate) fn set_lru_capacity(&self, len: usize) {
7777
let mut data = self.data.lock();
7878

7979
// We require each zone to have at least 1 slot. Therefore,
@@ -102,7 +102,7 @@ where
102102
}
103103

104104
/// Records that `node` was used. This may displace an old node (if the LRU limits are
105-
pub fn record_use(&self, node: &Arc<Node>) -> Option<Arc<Node>> {
105+
pub(crate) fn record_use(&self, node: &Arc<Node>) -> Option<Arc<Node>> {
106106
tracing::debug!("record_use(node={:?})", node);
107107

108108
// Load green zone length and check if the LRU cache is even enabled.
@@ -125,7 +125,7 @@ where
125125
self.data.lock().record_use(node)
126126
}
127127

128-
pub fn purge(&self) {
128+
pub(crate) fn purge(&self) {
129129
self.green_zone.store(0, Ordering::SeqCst);
130130
*self.data.lock() = LruData::with_seed(LRU_SEED);
131131
}

0 commit comments

Comments
 (0)