typeline_core/utils/
paths_store.rs1#![allow(unused)]
2#![allow(unused_variables)]
3use std::{collections::HashMap, num::NonZeroU32};
4
5use super::string_store::StringStoreEntry;
6
7type PathStoreEntry = NonZeroU32;
8
9type Path = [StringStoreEntry];
10
11pub struct PathStore {
12 indices: Vec<&'static Path>,
13 table: HashMap<&'static Path, PathStoreEntry>,
14 arena: Vec<Vec<StringStoreEntry>>,
15}
16
17impl PathStore {
18 fn add_path(path: &Path) -> &'static Path {
19 todo!()
20 }
21 pub fn intern(path: &Path) -> PathStoreEntry {
22 todo!()
23 }
24 pub fn try_lookup_entry(path: &Path) -> Option<PathStoreEntry> {
25 todo!()
26 }
27 pub fn lookup(path: &Path) -> PathStoreEntry {
28 todo!()
29 }
30}