HomePhabricator

[YAMLIO] Correctly diagnose empty alias/anchor

Authored by scott.linder on Nov 16 2020, 10:41 AM.

Description

[YAMLIO] Correctly diagnose empty alias/anchor

The Range of an alias/anchor token includes the leading & or *,
but it is skipped while parsing the name. The check for an empty name
fails to account for the skipped leading character and so the error is
never hit.

Fix the off-by-one and add a couple regression tests.

Reviewed By: dexonsmith

Differential Revision: https://reviews.llvm.org/D91462

Details

Committed
scott.linderNov 16 2020, 10:45 AM
Reviewer
dexonsmith
Differential Revision
D91462: [YAMLIO] Correctly diagnose empty alias/anchor
Parents
rGc37cc6bf7e15: [RISCV] Add MC tests for the User Vector CSRs
Branches
Unknown
Tags
Unknown