Skip to main content

Module string

Module string 

Source
Expand description

Shared string constants and hashing utility.

This module used to host a standalone LuaStringImpl/StringPool bootstrap string table (TString/stringtable from lstring.c), built solely to construct the pre-allocated out-of-memory message during VM startup. That subsystem was verified dead (issue #274): GlobalState bootstrap now calls LuaState::intern_str — the same interning path every other Lua string in the VM uses, backed by GlobalState::interned_lt — directly (see state.rs::init_memerrmsg). What remains here is the pure hash function and the short/long-string length threshold, both still shared with that real path and with the VM’s seed generation.