Closed ashottonoyan closed 8 years ago
I'm not 100% sure I agree with "If you want to swizzle, the best outcome is to leave no trace". Certainly it's necessary in some cases, but I like the hint something's been swizzled otherwise.
I'd probably accept a Pull Request that added a jr_swizzleMethodKeepingCmdName
/jr_swizzleClassMethodKeepingCmdName
alongside the existing jr_swizzleMethod
/jr_swizzleClassMethod
pair. That way folks can use it if necessary, but it's off by default.
What about the issue mentioned here? http://defagos.github.io/yet_another_article_about_method_swizzling/
Please don't just toss links at me. You are being inconsiderate of my time.
Instead, please make concrete suggestions. Ideally in the form of reproducible bug reports or Pull Requests.
Quite interesting how you deal with a 5mins article after I was pulling my hair off for hours trying to understand why my SDK conflicts with other SDKs which are swizzling too, and send you links with concrete possible issues.
You find it considerate of my time to spend time on fixing/testing the issue and creating a pull request because "you'd probably" accept it?
No matter how you feel about it, I won't re-describe the entire issue here in images as in the article, but the part that should interest you has the heading "Issues in class hierarchies" and contains this sentence "No swizzling implementation I encountered correctly deals with this issue, not even JRSwizzle.".
You would benefit from reading the entire article though.
Now I won't be wasting more of my and your time on trying to explain to you that your lib works fine only when there are no other libs used that swizzle and instead work on a solution that doesn't mess up or doesn't get messed by other libs/SDKs.
Hey @ashottonoyan,
I should have realized if you knew about these articles and are providing references, you are a skilled programmer and want to make JRSwizzle better. My brain yielded a false-positive and incorrectly categorized your Issue as please-do-my-homework-for-me.
I'm sorry that I miscategorized your Issue and I'm sorry JRSwizzle didn't live up to its claim of being your one-stop-shop for swizzling.
If you want to help out making JRSwizzle fulfill its goal (with credit to you, of course) I'd be very grateful for the help.
You should read this: https://blog.newrelic.com/2014/04/16/right-way-to-swizzle/