-
Notifications
You must be signed in to change notification settings - Fork 6k
[ObjC] generated method name's WithCompletionBlock
postfix doesn't follow convention?
#2121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
@hideya do you mean the postfix (WithCompletionBlock) is causing compiling error? |
@wing328 no, this is an improvement request, as e.g. |
WithCompletionBlock
postfix doesn't look correct?WithCompletionBlock
postfix doesn't follow convention?
I see. For the naming convention, do you have the URL to the style guide for our reference? |
Sure. Apple's Guide to Naming Methods says that:
|
Thanks for the URL. Using the example The easiest fix I can think of is to rename To fix it just for ObjC, one needs to customize the ObjC generator to provide another mustache tag (e.g. |
Thanks for the explanation. Yeah, I'd like to have it fixed just for ObjC. |
I don't mind. To me it's ok to make this breaking change (non-backward compatible) as your suggestion is better in terms of conforming to Apple's guidelines in naming method. Later we can include this in the release note or migration guide to make sure developers are informed of this breaking change when they upgrade to the next stable release. |
Thanks! I'll work on it then! |
[ObjC] Fix #2121, generated method names don't follow coding convention
API methods for Obj-C always seems to have
WithCompletionBlock
postfix, which doesn't follow the coding convention. For example, I think the following generated method:should have been like the following:
FYI, the yaml for this method is:
This is as of b54947d (the current latest) (@bajtos wanted to keep informed about this too)
The text was updated successfully, but these errors were encountered: