Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
yangql
googletest
Commits
66ac4909
Commit
66ac4909
authored
Mar 05, 2011
by
zhanyong.wan
Browse files
Fixes non-conforming uses of commas in enums s.t. the code compiles on
Sun OS. Patch by Hady Zalek.
parent
f4419791
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
test/gtest-printers_test.cc
test/gtest-printers_test.cc
+2
-2
test/gtest_unittest.cc
test/gtest_unittest.cc
+1
-1
No files found.
test/gtest-printers_test.cc
View file @
66ac4909
...
@@ -74,7 +74,7 @@ enum EnumWithoutPrinter {
...
@@ -74,7 +74,7 @@ enum EnumWithoutPrinter {
// An enum with a << operator.
// An enum with a << operator.
enum
EnumWithStreaming
{
enum
EnumWithStreaming
{
kEWS1
=
10
,
kEWS1
=
10
};
};
std
::
ostream
&
operator
<<
(
std
::
ostream
&
os
,
EnumWithStreaming
e
)
{
std
::
ostream
&
operator
<<
(
std
::
ostream
&
os
,
EnumWithStreaming
e
)
{
...
@@ -83,7 +83,7 @@ std::ostream& operator<<(std::ostream& os, EnumWithStreaming e) {
...
@@ -83,7 +83,7 @@ std::ostream& operator<<(std::ostream& os, EnumWithStreaming e) {
// An enum with a PrintTo() function.
// An enum with a PrintTo() function.
enum
EnumWithPrintTo
{
enum
EnumWithPrintTo
{
kEWPT1
=
1
,
kEWPT1
=
1
};
};
void
PrintTo
(
EnumWithPrintTo
e
,
std
::
ostream
*
os
)
{
void
PrintTo
(
EnumWithPrintTo
e
,
std
::
ostream
*
os
)
{
...
...
test/gtest_unittest.cc
View file @
66ac4909
...
@@ -3811,7 +3811,7 @@ TEST(AssertionTest, ExpectWorksWithUncopyableObject) {
...
@@ -3811,7 +3811,7 @@ TEST(AssertionTest, ExpectWorksWithUncopyableObject) {
enum NamedEnum {
enum NamedEnum {
kE1 = 0,
kE1 = 0,
kE2
=
1
,
kE2 = 1
};
};
TEST(AssertionTest, NamedEnum) {
TEST(AssertionTest, NamedEnum) {
...
...
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