Skip to content

Tasking Warning#10263

Closed
ejohnstown wants to merge 1 commit intowolfSSL:masterfrom
ejohnstown:tasking-warning
Closed

Tasking Warning#10263
ejohnstown wants to merge 1 commit intowolfSSL:masterfrom
ejohnstown:tasking-warning

Conversation

@ejohnstown
Copy link
Copy Markdown
Contributor

Description

Tasking compiler does not support #warning and needs the #pragma message case where available. This will fix the wolfSSH QNX nightly from failing. Similar fix to PR #10225.

Testing

The test for the QNX build of wolfSSH.

Checklist

  • added tests
  • updated/added doxygen
  • updated appropriate READMEs
  • Updated manual and documentation

Tasking compiler does not support #warning and needs the #pragma message
case where available. This will fix the wolfSSH QNX nightly from
failing.
Copilot AI review requested due to automatic review settings April 20, 2026 17:13
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Adjusts compile-time warning directives to support the TASKING compiler (and MSVC) by replacing unsupported #warning usage with #pragma message where needed, preventing QNX nightly failures.

Changes:

  • Wrapped existing #warning directives with compiler checks for _MSC_VER and __TASKING__.
  • Added #pragma message(...) fallbacks for compilers that don’t support #warning in this context.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +352 to +356
#if !defined(_MSC_VER) && !defined(__TASKING__)
#warning wolfssl/options.h included in compiled wolfssl library object.
#else
#pragma message("Warning: wolfssl/options.h included in compiled wolfssl library object.")
#endif
Copy link

Copilot AI Apr 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#pragma message("...") is MSVC-style syntax, but this branch also covers __TASKING__. If TASKING expects a different pragma-message form (commonly #pragma message "..." without parentheses), this may still fail on TASKING. Consider splitting the branches so _MSC_VER and __TASKING__ each use the exact syntax supported by their compiler, rather than sharing a single #pragma message spelling.

Copilot uses AI. Check for mistakes.
Comment on lines +376 to +380
#if !defined(_MSC_VER) && !defined(__TASKING__)
#warning "No configuration for wolfSSL detected, check header order"
#else
#pragma message("Warning: No configuration for wolfSSL detected, check header order")
#endif
Copy link

Copilot AI Apr 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The same compiler-conditional warning pattern is duplicated in multiple places. To reduce repetition (and the chance of future divergence between warning sites), consider introducing a small internal macro/helper in this header (e.g., a WOLFSSL_BUILD_WARNING(<text>)) and reuse it for both warning emissions.

Copilot uses AI. Check for mistakes.
@ejohnstown
Copy link
Copy Markdown
Contributor Author

Closing to change the name of the branch to something without "warning" in it.

@ejohnstown ejohnstown closed this Apr 20, 2026
@github-actions
Copy link
Copy Markdown

MemBrowse Memory Report

No memory changes detected for:

@ejohnstown ejohnstown deleted the tasking-warning branch April 21, 2026 22:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants