-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Toolchain: Add a note about weak functions and header files #4718
Conversation
LGTM |
/morph test |
platform/mbed_toolchain.h
Outdated
* | ||
* @note | ||
* Functions should only be marked as weak in the source file. The header file | ||
* should contain a regular function definition to insure the function is emitted. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
declaration instead of definition ?
It is the definition site which as to be marked as weak, not the declaration site.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, nice catch 👍
Result: SUCCESSYour command has finished executing! Here's what you wrote!
OutputAll builds and test passed! |
The subtlety of where to mark functions as weak created an issue for at least one user, so added a warning in the documentation.
/morph test |
Result: FAILUREYour command has finished executing! Here's what you wrote!
OutputTest failed! |
/morph test |
Result: FAILUREYour command has finished executing! Here's what you wrote!
OutputExample Build failed! |
@studavekar F429 for IAR one example keeps failing , CI results 2 days ago. |
/morph test |
Result: FAILUREYour command has finished executing! Here's what you wrote!
OutputTest failed! |
@0xc0170 from logs looks like compile fails and tools raised an exception.
Latest results shows test failure on NCS36510-IAR |
@studavekar That exception is just the assembler failing. It's not in addition to the assembler failing. |
/morph test |
Result: SUCCESSYour command has finished executing! Here's what you wrote!
OutputAll builds and test passed! |
The subtlety of where to mark functions as weak created an issue for at least one user, so added a warning in the documentation.
cc @marcuschangarm