rust-analyzer / rowan

Apache License 2.0
715 stars 61 forks source link

Fix prev_sibling indexing off-by-one #176

Closed milianw closed 1 week ago

milianw commented 1 week ago

The patch f06a2c903caa270e977a73ef5b9091f99e8fbe6c changed the code to use skip instead of nth, which lead to an off-by-one bug that was uncovered by unit tests in ludtwig, see 1.

Fixes: https://github.com/rust-analyzer/rowan/issues/175

lnicola commented 1 week ago

Ouch, thanks!