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
c6dffbcb
Commit
c6dffbcb
authored
9 years ago
by
Paul Yang
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #652 from TeBoring/objectivec
Move the definition of GOOGLE_FALLTHROUGH_INTENDED to port.h
parents
add3e8df
5da3fb06
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
13 deletions
+12
-13
map_entry_lite.h
src/google/protobuf/map_entry_lite.h
+0
-12
port.h
src/google/protobuf/stubs/port.h
+12
-1
No files found.
src/google/protobuf/map_entry_lite.h
View file @
c6dffbcb
...
...
@@ -162,19 +162,7 @@ class MapEntryLite : public MessageLite {
if
(
!
KeyWireHandler
::
Read
(
input
,
mutable_key
()))
return
false
;
set_has_key
();
if
(
!
input
->
ExpectTag
(
kValueTag
))
break
;
// BEGIN GOOGLE LOCAL MODIFICATION
// Add __has_cpp_attribute and NaCl and Emscripten checks.
#if defined(__clang__) && defined(__has_cpp_attribute) \
&& !defined(GOOGLE_PROTOBUF_OS_APPLE)
#if defined(GOOGLE_PROTOBUF_OS_NACL) || defined(EMSCRIPTEN)
[[
clang
::
fallthrough
]];
#elif __has_cpp_attribute(clang::fallthrough)
[[
clang
::
fallthrough
]];
#endif
#else
GOOGLE_FALLTHROUGH_INTENDED
;
#endif
// END GOOGLE LOCAL MODIFICATION
case
kValueTag
:
if
(
!
ValueWireHandler
::
Read
(
input
,
mutable_value
()))
return
false
;
...
...
This diff is collapsed.
Click to expand it.
src/google/protobuf/stubs/port.h
View file @
c6dffbcb
...
...
@@ -204,8 +204,19 @@ static const uint64 kuint64max = GOOGLE_ULONGLONG(0xFFFFFFFFFFFFFFFF);
#define GOOGLE_SAFE_CONCURRENT_WRITES_END()
#endif
#if defined(__clang__) && defined(__has_cpp_attribute) \
&& !defined(GOOGLE_PROTOBUF_OS_APPLE)
# if defined(GOOGLE_PROTOBUF_OS_NACL) || defined(EMSCRIPTEN) || \
__has_cpp_attribute(clang::fallthrough)
# define GOOGLE_FALLTHROUGH_INTENDED [[clang::fallthrough]]
# endif
#endif
#ifndef GOOGLE_FALLTHROUGH_INTENDED
# define GOOGLE_FALLTHROUGH_INTENDED
#endif
#define GOOGLE_GUARDED_BY(x)
#define GOOGLE_FALLTHROUGH_INTENDED
#define GOOGLE_ATTRIBUTE_COLD
// x86 and x86-64 can perform unaligned loads/stores directly.
...
...
This diff is collapsed.
Click to expand it.
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