From f64fa18502e3717bfa4a53307c324eb0201e0d0e Mon Sep 17 00:00:00 2001 From: Anonymous Maarten Date: Wed, 28 Aug 2019 19:11:03 +0200 Subject: [PATCH] closes bpo-37965: Fix compiler warning of distutils CCompiler.test_function. (GH-15560) https://bugs.python.org/issue37965 https://bugs.python.org/issue37965 Automerge-Triggered-By: @benjaminp (cherry picked from commit 55aabee07501e1468082b3237620e4ecd75c5da6) Co-authored-by: Anonymous Maarten --- Lib/distutils/ccompiler.py | 3 ++- .../next/Library/2019-08-28-14-04-18.bpo-37965.7xGE-C.rst | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 Misc/NEWS.d/next/Library/2019-08-28-14-04-18.bpo-37965.7xGE-C.rst diff --git a/Lib/distutils/ccompiler.py b/Lib/distutils/ccompiler.py index 1a411ed1113224..4cfc6c7065e922 100644 --- a/Lib/distutils/ccompiler.py +++ b/Lib/distutils/ccompiler.py @@ -781,8 +781,9 @@ def has_function(self, funcname, includes=None, include_dirs=None, for incl in includes: f.write("""#include "%s"\n""" % incl) f.write("""\ -main (int argc, char **argv) { +int main (int argc, char **argv) { %s(); + return 0; } """ % funcname) finally: diff --git a/Misc/NEWS.d/next/Library/2019-08-28-14-04-18.bpo-37965.7xGE-C.rst b/Misc/NEWS.d/next/Library/2019-08-28-14-04-18.bpo-37965.7xGE-C.rst new file mode 100644 index 00000000000000..116a9e49dccc18 --- /dev/null +++ b/Misc/NEWS.d/next/Library/2019-08-28-14-04-18.bpo-37965.7xGE-C.rst @@ -0,0 +1 @@ +Fix C compiler warning caused by distutils.ccompiler.CCompiler.has_function. pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy