From 556e623a8163062eb6929dd530e2bae120ceba07 Mon Sep 17 00:00:00 2001 From: Versus <3686499+versusvoid@users.noreply.github.com> Date: Thu, 20 Jan 2022 16:30:27 +0300 Subject: [PATCH] Add mmap.MAP_POPULATE from 3.10 (#6964) --- stdlib/mmap.pyi | 2 ++ tests/stubtest_allowlists/linux-py310.txt | 1 - 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/stdlib/mmap.pyi b/stdlib/mmap.pyi index b79ab92f0..e59f97320 100644 --- a/stdlib/mmap.pyi +++ b/stdlib/mmap.pyi @@ -13,6 +13,8 @@ ALLOCATIONGRANULARITY: int if sys.platform == "linux": MAP_DENYWRITE: int MAP_EXECUTABLE: int + if sys.version_info >= (3, 10): + MAP_POPULATE: int if sys.platform != "win32": MAP_ANON: int diff --git a/tests/stubtest_allowlists/linux-py310.txt b/tests/stubtest_allowlists/linux-py310.txt index dc131d830..a9d097674 100644 --- a/tests/stubtest_allowlists/linux-py310.txt +++ b/tests/stubtest_allowlists/linux-py310.txt @@ -20,7 +20,6 @@ select.epoll.register # Exists at runtime, but missing from stubs asyncio.PidfdChildWatcher asyncio.unix_events.PidfdChildWatcher -mmap.MAP_POPULATE os.EFD_CLOEXEC os.EFD_NONBLOCK os.EFD_SEMAPHORE