From ecc69bbd14a33eac2bf04bdcfcb459c73f0972c1 Mon Sep 17 00:00:00 2001 From: Andrew Plotkin Date: Sat, 13 May 2023 18:00:17 -0400 Subject: [PATCH] LanguageContraction() now operates on a byte/word array. --- .../Inter/EnglishLanguageKit/Sections/Language.i6t | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/inform7/Internal/Inter/EnglishLanguageKit/Sections/Language.i6t b/inform7/Internal/Inter/EnglishLanguageKit/Sections/Language.i6t index d604984b4..16f414fdc 100644 --- a/inform7/Internal/Inter/EnglishLanguageKit/Sections/Language.i6t +++ b/inform7/Internal/Inter/EnglishLanguageKit/Sections/Language.i6t @@ -169,9 +169,15 @@ Constant LanguageContractionForms = 2; ! English has two: ! 0 = starting with a consonant ! 1 = starting with a vowel -[ LanguageContraction text; - if (text->0 == 'a' or 'e' or 'i' or 'o' or 'u' - or 'A' or 'E' or 'I' or 'O' or 'U') return 1; +[ LanguageContraction text + ch; + #Ifdef TARGET_ZCODE; + ch = text->0; + #Ifnot; ! TARGET_GLULX + ch = text-->0; + #Endif; ! TARGET_ + if (ch == 'a' or 'e' or 'i' or 'o' or 'u' + or 'A' or 'E' or 'I' or 'O' or 'U') return 1; return 0; ];