Skip to content

proposal: x/sys/unix: add MmapPtr/MunmapPtr #67669

Closed
@ncruces

Description

@ncruces

Proposal Details

In github.com/ncruces/go-sqlite3 I'm go:linknaming mmap (I know, I'm sorry!) because I need unix.MAP_FIXED, which makes no sense for the version currently exported by either syscall or x/sys/unix.

Note that I'm currently link-naming syscall but could just as well use x/sys/unix (as I do for most everything else).

Link-naming is understandably discouraged, and on a path to being curtailed in #67401.

I know my package is pretty much irrelevant, but exposing the autogenerated bits that allow mmap to be called from a bunch of different Unixes would help. For example, I have no chance to test z/OS, but IBM is incentivized to add a portable version to x/sys/unix.

Hence, I'd like to propose x/sys/unix exports the uintptr version (or *byte?) of mmap, munmap and maybe mremap.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions