-
Notifications
You must be signed in to change notification settings - Fork 3k
Callback: Deprecate attach member function in favor of simple assignment #3783
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
Conversation
…ment The attach function is used several other places to indicate registration for interrupts. This differs significantly to its use in the Callback class. Additionally, the attach function is unnecessary given that simple assignment works just as well.
@geky I'm not sure I've opened an issue for this item but I certainly spoke of it informally and I very much welcome such change. It makes a lot of sense to treat callable objects like regular function pointer from a semantic perspective. |
/morph test |
Result: SUCCESSYour command has finished executing! Here's what you wrote!
OutputAll builds and test passed! |
/morph test-nightly |
Result: FAILUREYour command has finished executing! Here's what you wrote!
OutputBuild failed! |
/morph test-nightly |
Result: SUCCESSYour command has finished executing! Here's what you wrote!
OutputAll builds and test passed! |
@geky just to clarify: this is deprecting the |
Ah yes, this only effects the callback class (where attach behaved differently from other apis) |
The attach function is used several other places to indicate registration for interrupts. This differs significantly to its use in the Callback class. Additionally, the attach function is unnecessary given that simple assignment works just as well.
@pan-, I think this was being tracked in an issue of yours, but I can't find it now.
Hopefully we'll get a good chance to remove the bulk of these functions soon.
cc @pan-