lib/posix - Dropped 'T' from types

This commit is contained in:
pdw 2015-05-24 22:26:36 -05:00 • committed by Araq
commit 1c426c613c
4 changed files with 487 additions and 459 deletions

View file

@ -12,13 +12,14 @@
# Get the platform-dependent flags. # Get the platform-dependent flags.
# Structure describing an inotify event. # Structure describing an inotify event.
type type
Tinotify_event*{.pure, final, importc: "struct inotify_event", InotifyEvent*{.pure, final, importc: "struct inotify_event",
header: "<sys/inotify.h>".} = object header: "<sys/inotify.h>".} = object
wd*{.importc: "wd".}: cint # Watch descriptor. wd*{.importc: "wd".}: cint # Watch descriptor.
mask*{.importc: "mask".}: uint32 # Watch mask. mask*{.importc: "mask".}: uint32 # Watch mask.
cookie*{.importc: "cookie".}: uint32 # Cookie to synchronize two events. cookie*{.importc: "cookie".}: uint32 # Cookie to synchronize two events.
len*{.importc: "len".}: uint32 # Length (including NULs) of name. len*{.importc: "len".}: uint32 # Length (including NULs) of name.
name*{.importc: "name".}: char # Name. name*{.importc: "name".}: char # Name.
{.deprecated: [Tinotify_event: InotifyEvent].}
# Supported events suitable for MASK parameter of INOTIFY_ADD_WATCH. # Supported events suitable for MASK parameter of INOTIFY_ADD_WATCH.
const const

View file

@ -24,5 +24,5 @@ const
# fn should be of type proc (a2: pointer): void {.cdecl.} # fn should be of type proc (a2: pointer): void {.cdecl.}
proc clone*(fn: pointer; child_stack: pointer; flags: cint; proc clone*(fn: pointer; child_stack: pointer; flags: cint;
arg: pointer; ptid: ptr TPid; tls: pointer; arg: pointer; ptid: ptr Pid; tls: pointer;
ctid: ptr TPid): cint {.importc, header: "<sched.h>".} ctid: ptr Pid): cint {.importc, header: "<sched.h>".}

File diff suppressed because it is too large Load diff

View file

@ -12,17 +12,18 @@ import posix
type type
Speed* = cuint Speed* = cuint
Tcflag* = cuint Cflag* = cuint
{.deprecated: [Tcflag: Cflag].}
const const
NCCS* = 32 NCCS* = 32
type type
Termios* {.importc: "struct termios", header: "<termios.h>".} = object Termios* {.importc: "struct termios", header: "<termios.h>".} = object
c_iflag*: Tcflag # input mode flags c_iflag*: Cflag # input mode flags
c_oflag*: Tcflag # output mode flags c_oflag*: Cflag # output mode flags
c_cflag*: Tcflag # control mode flags c_cflag*: Cflag # control mode flags
c_lflag*: Tcflag # local mode flags c_lflag*: Cflag # local mode flags
c_line*: cuchar # line discipline c_line*: cuchar # line discipline
c_cc*: array[NCCS, cuchar] # control characters c_cc*: array[NCCS, cuchar] # control characters
@ -258,4 +259,4 @@ proc tcFlow*(fd: cint; action: cint): cint {.importc: "tcflow",
header: "<termios.h>".} header: "<termios.h>".}
# Get process group ID for session leader for controlling terminal FD. # Get process group ID for session leader for controlling terminal FD.
proc tcGetSid*(fd: cint): TPid {.importc: "tcgetsid", header: "<termios.h>".} proc tcGetSid*(fd: cint): Pid {.importc: "tcgetsid", header: "<termios.h>".}