8000 Don't discard result from QFile::open by nicolasfella · Pull Request #261 · qcoro/qcoro · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Don't discard result from QFile::open #261

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

Merged
merged 1 commit into from
Feb 8, 2025

Conversation

nicolasfella
Copy link
Contributor

QFile::open is nodiscard in Qt 6.9, breaking the build with -Werror

@danvratil
Copy link
Collaborator

Would you mind changing the name? MSVC doesn't like that it shadows another variable or something of the same name.

D:\a\qcoro\qcoro\examples\background-task\main.cpp(33,20): warning C4456: declaration of 'result' hides previous local declaration [D:\a\qcoro\qcoro\build\examples\background-task\background-task-example.vcxproj]

QFile::open is nodiscard in Qt 6.9, breaking the build with -Werror
@nicolasfella
Copy link
Contributor Author

Would you mind changing the name? MSVC doesn't like that it shadows another variable or something of the same name.

D:\a\qcoro\qcoro\examples\background-task\main.cpp(33,20): warning C4456: declaration of 'result' hides previous local declaration [D:\a\qcoro\qcoro\build\examples\background-task\background-task-example.vcxproj]

Done

@danvratil
Copy link
Collaborator

Thanks!

@danvratil danvratil merged commit 455cb4e into qcoro:main Feb 8, 2025
42 checks passed
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
0