gleam-lang/gleam · error

unexpected catch all size

Error message

unexpected catch all size

What it means

Error "unexpected catch all size" thrown in gleam-lang/gleam.

Source

Thrown at compiler-core/src/javascript/decision.rs:1576

                        self.read_size_to_doc(arena, size).expect("empty size"),
                        SPACE_GT_EQ_ZERO_DOCUMENT
                    ]
                }

                BitArrayTest::SegmentIsFiniteFloat {
                    read_action:
                        ReadAction {
                            from: start,
                            size,
                            endianness,
                            ..
                        },
                } => {
                    let start_doc = self.offset_to_doc(arena, start, false);
                    let end = match (start.constant_bits(), size.constant_bits()) {
                        (Some(start), _) if start == BigInt::ZERO => self
                            .read_size_to_doc(arena, size)
                            .expect("unexpected catch all size"),
                        (Some(start), Some(end)) => (start + end).to_doc(arena),
                        (_, _) => {
                            docvec![
                                arena,
                                start_doc,
                                SPACE_PLUS_SPACE_DOCUMENT,
                                self.read_size_to_doc(arena, size).expect("empty size")
                            ]
                        }
                    };
                    let check =
                        self.bit_array_slice_to_float(arena, value, start_doc, end, endianness);

                    docvec![
                        arena,
                        GLOBAL_THIS_DOT_NUMBER_DOT_IS_FINITE_OPEN_PAREN_DOCUMENT,
                        check,
                        CLOSE_PAREN_DOCUMENT

View on GitHub (pinned to 7e623aa83d)

When it happens

Trigger: Thrown at compiler-core/src/javascript/decision.rs:1576 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of gleam-lang/gleam@7e623aa83d (2026-08-17). Data as JSON: /api/errors/095e6bfb6f8a8e27. Report an issue: GitHub.