Skip to content

setting rowspan for grid.cell crashes the compiler #6399

@magistau

Description

@magistau

Description

MRE:

#set grid.cell(rowspan: 2)
#grid(columns: 2, [hehe]) 

Expected output: A blank page with hehe written in it.
Actual output:

thread 'main' panicked at crates/typst-layout/src/grid/rowspans.rs:132:35:
range end index 2 out of range for slice of length 1
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Got it on the web app (exists in all versions supporting grid.cell, including "development version"), reproduced on macOS to get the crash information.

Reproduction URL

No response

Operating system

macOS, Web app

Typst version

  • I am using the latest version of Typst

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcrashThe Typst compiler crashes for some inputlayoutRelated to the layout category, which is about composing, positioning, etc.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions