summaryrefslogtreecommitdiff
path: root/source/luametatex/source/tex/textextcodes.c
diff options
context:
space:
mode:
Diffstat (limited to 'source/luametatex/source/tex/textextcodes.c')
-rw-r--r--source/luametatex/source/tex/textextcodes.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/source/luametatex/source/tex/textextcodes.c b/source/luametatex/source/tex/textextcodes.c
index 2fef9857f..e76329685 100644
--- a/source/luametatex/source/tex/textextcodes.c
+++ b/source/luametatex/source/tex/textextcodes.c
@@ -54,10 +54,13 @@ void tex_set_cat_code(int h, int n, halfword v, int gl)
{
sa_tree_item item = { .uint_value = CATCODEDEFAULTS };
sa_tree tree = lmt_catcode_state.catcode_heads[h];
- if (h > lmt_catcode_state.catcode_max) {
- lmt_catcode_state.catcode_max = h;
- }
+// if (h > lmt_catcode_state.catcode_max) {
+// lmt_catcode_state.catcode_max = h;
+// }
if (! tree) {
+if (h > lmt_catcode_state.catcode_max) {
+ lmt_catcode_state.catcode_max = h;
+}
tree = sa_new_tree(CATCODESTACK, 1, item);
lmt_catcode_state.catcode_heads[h] = tree;
}
@@ -68,10 +71,13 @@ halfword tex_get_cat_code(int h, int n)
{
sa_tree_item item = { .uint_value = CATCODEDEFAULTS };
sa_tree tree = lmt_catcode_state.catcode_heads[h];
- if (h > lmt_catcode_state.catcode_max) {
- lmt_catcode_state.catcode_max = h;
- }
+// if (h > lmt_catcode_state.catcode_max) {
+// lmt_catcode_state.catcode_max = h;
+// }
if (! tree) {
+if (h > lmt_catcode_state.catcode_max) {
+ lmt_catcode_state.catcode_max = h;
+}
tree = sa_new_tree(CATCODESTACK, 1, item);
lmt_catcode_state.catcode_heads[h] = tree;
}