Carry resolved TeX command meanings through expansion
This commit is contained in:
1 parent
c6b5c9ed56
commit
93d3d38983
3 files changed
+87
-23
No files matched your search
@@ -156,6 +156,16 @@ fn expansion_order_let_ifx_noexpand_and_csname_follow_token_meanings() {
|
||||
assert_eq!(text(&execute(r"\ifx XBAD\else GOOD\fi")), "GOOD");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn backed_up_commands_see_changes_from_everypar_and_expandafter() {
|
||||
let result = execute(concat!(
|
||||
r"\let\chosen=A\def\change{\let\chosen=C}",
|
||||
r"\everypar{\let\chosen=B}",
|
||||
r"\chosen\expandafter\change\chosen\par",
|
||||
));
|
||||
assert_eq!(text(&result), "BC");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn skipped_branches_are_not_expanded_or_executed() {
|
||||
let result = execute(
|
||||
|
||||
Reference in new issue
Block a user