public void nextStateClass(CCStateArg arg, CClassNode ascCC, ScanEnvironment env) { if (arg.state == CCSTATE.RANGE) throw new SyntaxException(ErrorMessages.CHAR_CLASS_VALUE_AT_END_OF_RANGE); if (arg.state == CCSTATE.VALUE && arg.type != CCVALTYPE.CLASS) { if (arg.type == CCVALTYPE.SB) { bs.set(env, arg.from); if (ascCC != null) ascCC.bs.set(arg.from); } else if (arg.type == CCVALTYPE.CODE_POINT) { addCodeRange(env, arg.from, arg.from); if (ascCC != null) ascCC.addCodeRange(env, arg.from, arg.from, false); } } arg.state = CCSTATE.VALUE; arg.type = CCVALTYPE.CLASS; }
public void nextStateClass(CCStateArg arg, CClassNode ascCC, ScanEnvironment env) { if (arg.state == CCSTATE.RANGE) throw new SyntaxException(ErrorMessages.CHAR_CLASS_VALUE_AT_END_OF_RANGE); if (arg.state == CCSTATE.VALUE && arg.type != CCVALTYPE.CLASS) { if (arg.type == CCVALTYPE.SB) { bs.set(env, arg.from); if (ascCC != null) ascCC.bs.set(arg.from); } else if (arg.type == CCVALTYPE.CODE_POINT) { addCodeRange(env, arg.from, arg.from); if (ascCC != null) ascCC.addCodeRange(env, arg.from, arg.from, false); } } arg.state = CCSTATE.VALUE; arg.type = CCVALTYPE.CLASS; }
if (not) { for (int c=0; c<BitSet.SINGLE_BYTE_SIZE; c++) { if (!enc.isCodeCType(c, ctype)) bs.set(env, c); if (enc.isCodeCType(c, ctype)) bs.set(env, c); if (not) { for (int c=0; c<BitSet.SINGLE_BYTE_SIZE; c++) { if (!enc.isCodeCType(c, ctype) || c >= maxCode) bs.set(env, c); if (enc.isCodeCType(c, ctype)) bs.set(env, c); if (!not) { for (int c=0; c<maxCode; c++) { if (enc.isSbWord(c)) bs.set(env, c); for (int c=0; c<BitSet.SINGLE_BYTE_SIZE; c++) { if (enc.codeToMbcLength(c) > 0 && /* check invalid code point */ !(enc.isWord(c) || c >= maxCode)) bs.set(env, c);
public void setRange(ScanEnvironment env, int from, int to) { for (int i=from; i<=to && i < SINGLE_BYTE_SIZE; i++) { if (env != null && at(i)) env.ccDuplicateWarn(); set(i); } }
if (not) { for (int c=0; c<BitSet.SINGLE_BYTE_SIZE; c++) { if (!enc.isCodeCType(c, ctype)) bs.set(env, c); if (enc.isCodeCType(c, ctype)) bs.set(env, c); if (not) { for (int c=0; c<BitSet.SINGLE_BYTE_SIZE; c++) { if (!enc.isCodeCType(c, ctype) || c >= maxCode) bs.set(env, c); if (enc.isCodeCType(c, ctype)) bs.set(env, c); if (!not) { for (int c=0; c<maxCode; c++) { if (enc.isSbWord(c)) bs.set(env, c); for (int c=0; c<BitSet.SINGLE_BYTE_SIZE; c++) { if (enc.codeToMbcLength(c) > 0 && /* check invalid code point */ !(enc.isWord(c) || c >= maxCode)) bs.set(env, c);
public void setRange(ScanEnvironment env, int from, int to) { for (int i=from; i<=to && i < SINGLE_BYTE_SIZE; i++) { if (env != null && at(i)) env.ccDuplicateWarn(); set(i); } }
public void set(ScanEnvironment env, int pos) { if (at(pos)) env.ccDuplicateWarn(); set(pos); }
public void set(ScanEnvironment env, int pos) { if (at(pos)) env.ccDuplicateWarn(); set(pos); }
if (enc.isNewLine(NEW_LINE)) { if (enc.codeToMbcLength(NEW_LINE) == 1) { cc.bs.set(env, NEW_LINE); } else { cc.addCodeRange(env, NEW_LINE, NEW_LINE);
if (enc.isNewLine(NEW_LINE)) { if (enc.codeToMbcLength(NEW_LINE) == 1) { cc.bs.set(env, NEW_LINE); } else { cc.addCodeRange(env, NEW_LINE, NEW_LINE);