module RBS::WASM::SerializationSchema
Describes how to decode the binary buffer produced by rbs_serialize_node (src/serialize.c) back into RBS::AST objects. RBS::WASM::Deserializer walks this table; the matching encoder is generated from the same config.yml, so the two stay in sync.
SCHEMA is indexed by node tag: tag 0 is NULL and SYMBOL_TAG is the interned-symbol tag. Each remaining entry is one of:
[:node, class_name, expose_location, loc_children, fields, resolve_type_params] [:bool] / [:integer] / [:string_value] / [:record_field] [:signature] / [:namespace] / [:type_name]
where loc_children is [[name, required?], …] and fields is
- [name, reader], …
-
with reader one of :node, :node_list, :hash, :string,
:bool, :location_range, :location_range_list, :attr_ivar_name, or [:enum, [value_or_nil, …]].
Generated from config.yml. See templates/lib/rbs/wasm/serialization_schema.rb.erb.
Constants
- SCHEMA
-
Indexed by node tag. Each entry describes how to decode one node; see the generated file for the exact shape.
- SYMBOL_TAG
-
The node tag used for interned symbols (
rbs_ast_symbol).