cl-structures::Interned: Change to_ref() from assoc. function to member function

(it's so much nicer)
This commit is contained in:
2025-03-12 01:16:51 -05:00
parent dcdb100a8a
commit 584207fc8c
6 changed files with 10 additions and 10 deletions

View File

@@ -320,9 +320,9 @@ fn banner() {
/// Interns a [File](cl_ast::File), returning a static reference to it.
fn interned(file: cl_ast::File) -> &'static cl_ast::File {
use cl_structures::intern::{interned::Interned, typed_interner::TypedInterner};
use cl_structures::intern::typed_interner::TypedInterner;
static INTERNER: LazyLock<TypedInterner<'static, cl_ast::File>> =
LazyLock::new(Default::default);
Interned::to_ref(&INTERNER.get_or_insert(file))
INTERNER.get_or_insert(file).to_ref()
}