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
a3873caf
Commit
a3873caf
authored
Apr 18, 2017
by
Thomas Van Lenten
Committed by
GitHub
Apr 18, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2985 from thomasvl/class_check_tweaks
Tighten up class usage/checks.
parents
8aa927f0
f5a01d1b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
GPBMessage.m
objectivec/GPBMessage.m
+2
-2
No files found.
objectivec/GPBMessage.m
View file @
a3873caf
...
...
@@ -130,7 +130,7 @@ static NSError *ErrorFromException(NSException *exception) {
static
void
CheckExtension
(
GPBMessage
*
self
,
GPBExtensionDescriptor
*
extension
)
{
if
(
[
self
class
]
!=
extension
.
containingMessageClass
)
{
if
(
!
[
self
isKindOfClass
:
extension
.
containingMessageClass
]
)
{
[
NSException
raise
:
NSInvalidArgumentException
format
:
@"Extension %@ used on wrong class (%@ instead of %@)"
,
...
...
@@ -3189,7 +3189,7 @@ static void ResolveIvarSet(GPBFieldDescriptor *field,
+
(
BOOL
)
resolveClassMethod
:(
SEL
)
sel
{
// Extensions scoped to a Message and looked up via class methods.
if
(
GPBResolveExtensionClassMethod
(
self
,
sel
))
{
if
(
GPBResolveExtensionClassMethod
(
[
self
descriptor
].
messageClass
,
sel
))
{
return
YES
;
}
return
[
super
resolveClassMethod
:
sel
];
...
...
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