From a86a0f235b981870904867dfa87402df1f0159fa Mon Sep 17 00:00:00 2001 From: dchandler Date: Sun, 13 Jul 2003 17:38:00 +0000 Subject: [PATCH] I was missing a break; statement; this caused an Error to be thrown during some TMW->Wylie conversions. No conversions were erroneous, though. --- source/org/thdl/tib/text/TibTextUtils.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/source/org/thdl/tib/text/TibTextUtils.java b/source/org/thdl/tib/text/TibTextUtils.java index 6f62e9b..4aaebfc 100644 --- a/source/org/thdl/tib/text/TibTextUtils.java +++ b/source/org/thdl/tib/text/TibTextUtils.java @@ -950,6 +950,7 @@ public class TibTextUtils implements THDLWylieConstants { } else if (TGCPair.SANSKRIT_WITHOUT_VOWEL == cls || TGCPair.SANSKRIT_WITH_VOWEL == cls) { candidateType = "invalid"; + break; } else if (TGCPair.CONSONANTAL_WITHOUT_VOWEL == cls || TGCPair.CONSONANTAL_WITH_VOWEL == cls) { if (null == candidateType) { @@ -1126,8 +1127,10 @@ public class TibTextUtils implements THDLWylieConstants { break; } } else { + if ("invalid" == candidateType) + throw new Error("forgot to break out of the for loop after diagnosing invalidity."); if ("number" != candidateType) - throw new Error("missed a case"); + throw new Error("missed a case; case is " + candidateType); if (null != warnings) warnings.append("Found a consonant or consonant stack after something odd; the consonantish thing has wylie " + wylie + "\n"); candidateType = "invalid";