-
-
Notifications
You must be signed in to change notification settings - Fork 32.1k
GH-131296: fix clang-cl parentheses warnings on Windows #131905
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6111,7 +6111,7 @@ _ssl_enum_certificates_impl(PyObject *module, const char *store_name) | |
return PyErr_SetFromWindowsErr(GetLastError()); | ||
} | ||
|
||
while (pCertCtx = CertEnumCertificatesInStore(hCollectionStore, pCertCtx)) { | ||
while ((pCertCtx = CertEnumCertificatesInStore(hCollectionStore, pCertCtx))) { | ||
cert = PyBytes_FromStringAndSize((const char*)pCertCtx->pbCertEncoded, | ||
pCertCtx->cbCertEncoded); | ||
if (!cert) { | ||
|
@@ -6210,7 +6210,7 @@ _ssl_enum_crls_impl(PyObject *module, const char *store_name) | |
return PyErr_SetFromWindowsErr(GetLastError()); | ||
} | ||
|
||
while (pCrlCtx = CertEnumCRLsInStore(hCollectionStore, pCrlCtx)) { | ||
while ((pCrlCtx = CertEnumCRLsInStore(hCollectionStore, pCrlCtx))) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fix warning : using the result of an assignment as a condition without parentheses [-Wparentheses]. |
||
crl = PyBytes_FromStringAndSize((const char*)pCrlCtx->pbCrlEncoded, | ||
pCrlCtx->cbCrlEncoded); | ||
if (!crl) { | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5372,7 +5372,7 @@ _testFileExistsByName(LPCWSTR path, BOOL followLinks) | |
sizeof(info))) | ||
{ | ||
if (!(info.FileAttributes & FILE_ATTRIBUTE_REPARSE_POINT) || | ||
!followLinks && IsReparseTagNameSurrogate(info.ReparseTag)) | ||
(!followLinks && IsReparseTagNameSurrogate(info.ReparseTag))) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fix warning : '&&' within '||' [-Wlogical-op-parentheses]. |
||
{ | ||
return TRUE; | ||
} | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2760,7 +2760,7 @@ process(int argc, wchar_t ** argv) | |
// We searched earlier, so if we didn't find anything, now we react | ||
exitCode = searchExitCode; | ||
// If none found, and if permitted, install it | ||
if (exitCode == RC_NO_PYTHON && isEnvVarSet(L"PYLAUNCHER_ALLOW_INSTALL") || | ||
if (((exitCode == RC_NO_PYTHON) && isEnvVarSet(L"PYLAUNCHER_ALLOW_INSTALL")) || | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fix warning : '&&' within '||' [-Wlogical-op-parentheses]. |
||
isEnvVarSet(L"PYLAUNCHER_ALWAYS_INSTALL")) { | ||
exitCode = installEnvironment(&search); | ||
if (!exitCode) { | ||
|
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.
Fix warning : using the result of an assignment as a condition without parentheses [-Wparentheses].