diff --git a/source/com/intellij/codeInsight/template/impl/_TemplateTextLexer.java b/source/com/intellij/codeInsight/template/impl/_TemplateTextLexer.java index 38c4830b0518..1804a8aff817 100644 --- a/source/com/intellij/codeInsight/template/impl/_TemplateTextLexer.java +++ b/source/com/intellij/codeInsight/template/impl/_TemplateTextLexer.java @@ -1,4 +1,4 @@ -/* The following code was generated by JFlex 1.4 on 3/26/05 7:16 PM */ +/* The following code was generated by JFlex 1.4 on 3/26/05 7:57 PM */ /* It's an automatically generated code. Do not modify it. */ package com.intellij.codeInsight.template.impl; @@ -10,7 +10,7 @@ import com.intellij.psi.tree.IElementType; /** * This class is a scanner generated by * JFlex 1.4 - * on 3/26/05 7:16 PM from the specification file + * on 3/26/05 7:57 PM from the specification file * C:/Irida/tools/lexer/TemplateTextLexer.flex */ class _TemplateTextLexer implements FlexLexer { @@ -23,16 +23,14 @@ class _TemplateTextLexer implements FlexLexer { /** * Translates characters to character classes */ - private static final char [] ZZ_CMAP = { - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, - 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, - 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0 - }; + private static final String ZZ_CMAP_PACKED = + "\44\0\1\2\13\0\12\1\7\0\32\1\4\0\1\1\1\0\32\1"+ + "\uff85\0"; + + /** + * Translates characters to character classes + */ + private static final char [] ZZ_CMAP = zzUnpackCMap(ZZ_CMAP_PACKED); /** * Translates DFA states to action switch labels. @@ -216,6 +214,24 @@ class _TemplateTextLexer implements FlexLexer { this(new java.io.InputStreamReader(in)); } + /** + * Unpacks the compressed character translation table. + * + * @param packed the packed character translation table + * @return the unpacked character translation table + */ + private static char [] zzUnpackCMap(String packed) { + char [] map = new char[0x10000]; + int i = 0; /* index in packed string */ + int j = 0; /* index in unpacked array */ + while (i < 22) { + int count = packed.charAt(i++); + char value = packed.charAt(i++); + do map[j++] = value; while (--count > 0); + } + return map; + } + public final int getTokenStart(){ return zzStartRead - zzPushbackPos; } diff --git a/source/com/intellij/ide/fileTemplates/impl/FileTemplateTextLexer.java b/source/com/intellij/ide/fileTemplates/impl/FileTemplateTextLexer.java index 7c2341ad7cae..376ffc61dea8 100644 --- a/source/com/intellij/ide/fileTemplates/impl/FileTemplateTextLexer.java +++ b/source/com/intellij/ide/fileTemplates/impl/FileTemplateTextLexer.java @@ -1,4 +1,4 @@ -/* The following code was generated by JFlex 1.4 on 3/26/05 7:11 PM */ +/* The following code was generated by JFlex 1.4 on 3/26/05 7:57 PM */ /* It's an automatically generated code. Do not modify it. */ package com.intellij.ide.fileTemplates.impl; @@ -10,7 +10,7 @@ import com.intellij.psi.tree.IElementType; /** * This class is a scanner generated by * JFlex 1.4 - * on 3/26/05 7:11 PM from the specification file + * on 3/26/05 7:57 PM from the specification file * C:/Irida/tools/lexer/FileTemplateTextLexer.flex */ class FileTemplateTextLexer implements FlexLexer { @@ -23,16 +23,14 @@ class FileTemplateTextLexer implements FlexLexer { /** * Translates characters to character classes */ - private static final char [] ZZ_CMAP = { - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 6, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 0, 0, 0, 0, 0, 0, - 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, - 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 4, 0, 5, 0, 0 - }; + private static final String ZZ_CMAP_PACKED = + "\43\0\1\6\1\3\13\0\12\2\7\0\32\1\4\0\1\1\1\0"+ + "\32\1\1\4\1\0\1\5\uff82\0"; + + /** + * Translates characters to character classes + */ + private static final char [] ZZ_CMAP = zzUnpackCMap(ZZ_CMAP_PACKED); /** * Translates DFA states to action switch labels. @@ -219,6 +217,24 @@ class FileTemplateTextLexer implements FlexLexer { this(new java.io.InputStreamReader(in)); } + /** + * Unpacks the compressed character translation table. + * + * @param packed the packed character translation table + * @return the unpacked character translation table + */ + private static char [] zzUnpackCMap(String packed) { + char [] map = new char[0x10000]; + int i = 0; /* index in packed string */ + int j = 0; /* index in unpacked array */ + while (i < 30) { + int count = packed.charAt(i++); + char value = packed.charAt(i++); + do map[j++] = value; while (--count > 0); + } + return map; + } + public final int getTokenStart(){ return zzStartRead - zzPushbackPos; }