[Python-ideas] Adding shm_open to mmap?

Nick Coghlan ncoghlan at gmail.com
Wed Feb 15 04:07:54 CET 2012


On Wed, Feb 15, 2012 at 12:25 PM, Mike Meyer <mwm at mired.org> wrote:
> On Wed, 15 Feb 2012 10:07:23 +1000
> Nick Coghlan <ncoghlan at gmail.com> wrote:
>
>> On Wed, Feb 15, 2012 at 9:50 AM, Mike Meyer <mwm at mired.org> wrote:
>> > This seems like a slam-dunk to me, but...
>> > 1) Is there some reason not to just add these two functions?
>> Not that I can see. Make sure to add an "Availabilty: Unix" marker in
>> the relevant docs, though.
>
> I thought Windows was a Posix system?

Not as far as I am aware - if it was, Cygwin wouldn't be needed as a
compatibility layer to get POSIX software running.

To get them to work properly on Windows, many modules that interface
with the OS have to use the win32 API directly rather than relying on
the native implementations of the POSIX APIs.

> As such, it should have shm_open
> and shm_unlink, so the market wouldn't be appropriate.

In this case, it sounds like Windows may already have a roughly
equivalent mechanism in mmap, so cross-platform support may be
feasible. If that's the case, a marker won't be needed.

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia



More information about the Python-ideas mailing list