1
Fork 0

rmeta/query cache: don't write string values of preinterned symbols

This commit is contained in:
klensy 2022-08-20 15:39:21 +03:00
parent 0016356f2b
commit f6329485a8
5 changed files with 51 additions and 22 deletions

View file

@ -1803,6 +1803,11 @@ impl Symbol {
Symbol(SymbolIndex::from_u32(n))
}
/// for use in Decoder only
pub fn new_from_decoded(n: u32) -> Self {
Self::new(n)
}
/// Maps a string to its interned representation.
pub fn intern(string: &str) -> Self {
with_session_globals(|session_globals| session_globals.symbol_interner.intern(string))