Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
P
protobuf
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
protobuf
Commits
6f12e3e2
Commit
6f12e3e2
authored
Dec 22, 2009
by
kenton@google.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Accept form feeds as whitespace.
parent
f9c5978f
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
1 deletion
+8
-1
tokenizer.cc
src/google/protobuf/io/tokenizer.cc
+1
-1
tokenizer_unittest.cc
src/google/protobuf/io/tokenizer_unittest.cc
+7
-0
No files found.
src/google/protobuf/io/tokenizer.cc
View file @
6f12e3e2
...
...
@@ -117,7 +117,7 @@ namespace {
}
CHARACTER_CLASS
(
Whitespace
,
c
==
' '
||
c
==
'\n'
||
c
==
'\t'
||
c
==
'\r'
||
c
==
'\v'
);
c
==
'\r'
||
c
==
'\v'
||
c
==
'\f'
);
CHARACTER_CLASS
(
Unprintable
,
c
<
' '
&&
c
>
'\0'
);
...
...
src/google/protobuf/io/tokenizer_unittest.cc
View file @
6f12e3e2
...
...
@@ -403,6 +403,13 @@ MultiTokenCase kMultiTokenCases[] = {
{
Tokenizer
::
TYPE_SYMBOL
,
"
\300
"
,
0
,
0
},
{
Tokenizer
::
TYPE_END
,
""
,
0
,
1
},
}},
// Test all whitespace chars
{
"foo
\n\t\r\v\f
bar"
,
{
{
Tokenizer
::
TYPE_IDENTIFIER
,
"foo"
,
0
,
0
},
{
Tokenizer
::
TYPE_IDENTIFIER
,
"bar"
,
1
,
11
},
{
Tokenizer
::
TYPE_END
,
""
,
1
,
14
},
}},
};
TEST_2D
(
TokenizerTest
,
MultipleTokens
,
kMultiTokenCases
,
kBlockSizes
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment