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,
- 128, 128, 0, 128, 128, 128, 128, 128,
+ 0, 128, 128, 128, 128, 128, 128, 128,
128, 128, 128, 128, 128, 128, 128, 128,
- 128, 128, 128, 0, 0, 128, 0, 0,
+ 128, 128, 128, 128, 128, 128, 128, 128,
+ 128, 128, 128, 128, 128, 128, 0, 0,
128, 128, 128, 128, 128, 128, 128, 128,
128, 128, 128, 128, 128, 128, 128, 128,
128, 128, 128, 128, 128, 128, 128, 128,
};
yych = *in;
- if (yych <= 'Z') {
- if (yych <= '*') {
+ if (yych <= '\\') {
+ if (yych <= '=') {
if (yych <= 0x00) goto yy6;
- if (yych <= '\'') goto yy8;
- if (yych <= ')') goto yy4;
- goto yy8;
+ if (yych <= ' ') goto yy8;
+ goto yy4;
} else {
- if (yych <= '<') {
- if (yych <= ':') goto yy4;
- goto yy8;
- } else {
- if (yych <= '=') goto yy4;
- if (yych <= '?') goto yy8;
- goto yy4;
- }
+ if (yych <= '?') goto yy8;
+ if (yych <= 'Z') goto yy4;
+ if (yych <= '[') goto yy8;
}
} else {
- if (yych <= '_') {
- if (yych == '\\') goto yy2;
- if (yych <= '^') goto yy8;
- goto yy4;
+ if (yych <= '`') {
+ if (yych == '_') goto yy4;
+ goto yy8;
} else {
- if (yych <= 'z') {
- if (yych <= '`') goto yy8;
- goto yy4;
- } else {
- if (yych == '~') goto yy4;
- goto yy8;
- }
+ if (yych <= 'z') goto yy4;
+ if (yych == '~') goto yy4;
+ goto yy8;
}
}
-yy2:
++in;
if ((yych = *in) <= '$') {
if (yych <= '\n') {
}
TEST_F(DepfileParserTest, SpecialChars) {
+ // See filenames like istreambuf.iterator_op!= in
+ // https://github.com/google/libcxx/tree/master/test/iterators/stream.iterators/istreambuf.iterator/
string err;
EXPECT_TRUE(Parse(
"C:/Program\\ Files\\ (x86)/Microsoft\\ crtdefs.h: \n"
-" en@quot.header~ t+t-x=1",
+" en@quot.header~ t+t-x!=1",
&err));
ASSERT_EQ("", err);
EXPECT_EQ("C:/Program Files (x86)/Microsoft crtdefs.h",
ASSERT_EQ(2u, parser_.ins_.size());
EXPECT_EQ("en@quot.header~",
parser_.ins_[0].AsString());
- EXPECT_EQ("t+t-x=1",
+ EXPECT_EQ("t+t-x!=1",
parser_.ins_[1].AsString());
}