// Preserves Values. import type { Bytes } from './bytes'; import type { DoubleFloat } from './float'; import type { Annotated } from './annotated'; import type { Set, Dictionary } from './dictionary'; import type { Embedded, GenericEmbedded } from './embedded'; export type Value = | Atom | Compound | Embedded | Annotated; export type Atom = | boolean | DoubleFloat | number | bigint | string | Bytes | symbol; export type Compound = | (Array> | [Value]) & { label: Value } // ^ expanded from definition of Record<> in record.ts, // because if we use Record, Tuple>, T>, // TypeScript currently complains about circular use of Value, // and if we use Record, it accepts it but collapses // Value to any. | Array> | Set | Dictionary;