Code view:

A painting is a person's account of this edit as text, recorded independently of the node mapping - a rendering often has several equally defensible answers where the mapping has one. Deletions and insertions carry no position on the opposite side in a painting, so that panel draws no caret for them.

Before

…lines 1–866 unchanged (866 lines)
867//sys GetAcceptExSockaddrs(buf *byte, rxdatalen uint32, laddrlen uint32, raddrlen uint32, lrsa **RawSockaddrAny, lrsalen *int32, rrsa **RawSockaddrAny, rrsalen *int32) = mswsock.GetAcceptExSockaddrs
868//sys WSARecv(s Handle, bufs *WSABuf, bufcnt uint32, recvd *uint32, flags *uint32, overlapped *Overlapped, croutine *byte) (err error) [failretval==socket_error] = ws2_32.WSARecv
869//sys WSASend(s Handle, bufs *WSABuf, bufcnt uint32, sent *uint32, flags uint32, overlapped *Overlapped, croutine *byte) (err error) [failretval==socket_error] = ws2_32.WSASend
870//sys WSARecvFrom(s Handle, bufs *WSABuf, bufcnt uint32, recvd *uint32, flags *uint32, from *RawSockaddrAny, fromlen *int32, overlapped *Overlapped, croutine *byte) (err error) [failretval==socket_error] = ws2_32.WSARecvFrom
871//sys WSASendTo(s Handle, bufs *WSABuf, bufcnt uint32, sent *uint32, flags uint32, to *RawSockaddrAny, tolen int32, overlapped *Overlapped, croutine *byte) (err error) [failretval==socket_error] = ws2_32.WSASendTo
872//sys WSASocket(af int32, typ int32, protocol int32, protoInfo *WSAProtocolInfo, group uint32, flags uint32) (handle Handle, err error) [failretval==InvalidHandle] = ws2_32.WSASocketW
873//sys GetHostByName(name string) (h *Hostent, err error) [failretval==nil] = ws2_32.gethostbyname
874//sys GetServByName(name string, proto string) (s *Servent, err error) [failretval==nil] = ws2_32.getservbyname
875//sys Ntohs(netshort uint16) (u uint16) = ws2_32.ntohs
876//sys GetProtoByName(name string) (p *Protoent, err error) [failretval==nil] = ws2_32.getprotobyname
877//sys DnsQuery(name string, qtype uint16, options uint32, extra *byte, qrs **DNSRecord, pr *byte) (status error) = dnsapi.DnsQuery_W
878//sys DnsRecordListFree(rl *DNSRecord, freetype uint32) = dnsapi.DnsRecordListFree
879//sys DnsNameCompare(name1 *uint16, name2 *uint16) (same bool) = dnsapi.DnsNameCompare_W
…lines 880–1694 unchanged (815 lines)
1695 Buffer: &s16[0],
1696 }, nil
1697}
1698
1699// Slice returns a uint16 slice that aliases the data in the NTUnicodeString.
1700func (s *NTUnicodeString) Slice() []uint16 {
1701 slice := unsafe.Slice(s.Buffer, s.MaximumLength)
1702 return slice[:s.Length]
1703}
1704
1705func (s *NTUnicodeString) String() string {
1706 return UTF16ToString(s.Slice())
1707}
1708
…lines 1709–1933 unchanged (225 lines)

After

…lines 1–866 unchanged (866 lines)
867//sys GetAcceptExSockaddrs(buf *byte, rxdatalen uint32, laddrlen uint32, raddrlen uint32, lrsa **RawSockaddrAny, lrsalen *int32, rrsa **RawSockaddrAny, rrsalen *int32) = mswsock.GetAcceptExSockaddrs
868//sys WSARecv(s Handle, bufs *WSABuf, bufcnt uint32, recvd *uint32, flags *uint32, overlapped *Overlapped, croutine *byte) (err error) [failretval==socket_error] = ws2_32.WSARecv
869//sys WSASend(s Handle, bufs *WSABuf, bufcnt uint32, sent *uint32, flags uint32, overlapped *Overlapped, croutine *byte) (err error) [failretval==socket_error] = ws2_32.WSASend
870//sys WSARecvFrom(s Handle, bufs *WSABuf, bufcnt uint32, recvd *uint32, flags *uint32, from *RawSockaddrAny, fromlen *int32, overlapped *Overlapped, croutine *byte) (err error) [failretval==socket_error] = ws2_32.WSARecvFrom
871//sys WSASendTo(s Handle, bufs *WSABuf, bufcnt uint32, sent *uint32, flags uint32, to *RawSockaddrAny, tolen int32, overlapped *Overlapped, croutine *byte) (err error) [failretval==socket_error] = ws2_32.WSASendTo
872//sys WSASocket(af int32, typ int32, protocol int32, protoInfo *WSAProtocolInfo, group uint32, flags uint32) (handle Handle, err error) [failretval==InvalidHandle] = ws2_32.WSASocketW
873//sys WSADuplicateSocket(s Handle, processID uint32, info *WSAProtocolInfo) (err error) [failretval!=0] = ws2_32.WSADuplicateSocketW
874//sys GetHostByName(name string) (h *Hostent, err error) [failretval==nil] = ws2_32.gethostbyname
875//sys GetServByName(name string, proto string) (s *Servent, err error) [failretval==nil] = ws2_32.getservbyname
876//sys Ntohs(netshort uint16) (u uint16) = ws2_32.ntohs
877//sys GetProtoByName(name string) (p *Protoent, err error) [failretval==nil] = ws2_32.getprotobyname
878//sys DnsQuery(name string, qtype uint16, options uint32, extra *byte, qrs **DNSRecord, pr *byte) (status error) = dnsapi.DnsQuery_W
879//sys DnsRecordListFree(rl *DNSRecord, freetype uint32) = dnsapi.DnsRecordListFree
…lines 880–1695 unchanged (816 lines)
1696 Buffer: &s16[0],
1697 }, nil
1698}
1699
1700// Slice returns a uint16 slice that aliases the data in the NTUnicodeString.
1701func (s *NTUnicodeString) Slice() []uint16 {
1702 // Note: this rounds the length down, if it happens
1703 // to (incorrectly) be odd. Probably safer than rounding up.
1704 return unsafe.Slice(s.Buffer, s.MaximumLength/2)[:s.Length/2]
1705}
1706
1707func (s *NTUnicodeString) String() string {
1708 return UTF16ToString(s.Slice())
1709}
1710
…lines 1711–1935 unchanged (225 lines)

Before

source_file
comment "// Copyright 2009 The Go Authors. All rights reserved."
comment "// Use of this source code is governed by a BSD-style"
comment "// license that can be found in the LICENSE file."
comment "// Windows system calls."
package_clause
package "package"
package_identifier "windows"
import_declaration (+46 nodes collapsed)
type_declaration
type "type"
( "("
type_spec
type_identifier "Handle"
type_identifier "uintptr"
type_spec
type_identifier "HWND"
type_identifier "uintptr"
) ")"
const_declaration (+203 nodes collapsed)
comment "// StringToUTF16 is deprecated. Use UTF16FromString instead."
comment "// If s contains a NUL byte this function panics instead of"
comment "// returning an error."
function_declaration (+54 nodes collapsed)
comment "// UTF16FromString returns the UTF-16 encoding of the UTF-8 "...
comment "// s, with a terminating NUL added. If s contains a NUL byte"...
comment "// location, it returns (nil, syscall.EINVAL)."
function_declaration (+36 nodes collapsed)
comment "// UTF16ToString returns the UTF-8 encoding of the UTF-16 se"...
comment "// with a terminating NUL and any bytes after the NUL remove"...
function_declaration (+29 nodes collapsed)
comment "// StringToUTF16Ptr is deprecated. Use UTF16PtrFromString in"...
comment "// If s contains a NUL byte this function panics instead of"
comment "// returning an error."
function_declaration (+31 nodes collapsed)
comment "// UTF16PtrFromString returns pointer to the UTF-16 encoding"...
comment "// the UTF-8 string s, with a terminating NUL added. If s"
comment "// contains a NUL byte at any location, it returns (nil, sys"...
function_declaration (+64 nodes collapsed)
comment "// UTF16PtrToString takes a pointer to a UTF-16 sequence and"...
comment "// If the pointer is nil, it returns the empty string. It as"...
comment "// at a zero word; if the zero word is not present, the prog"...
function_declaration (+150 nodes collapsed)
function_declaration
func "func"
identifier "Getpagesize"
parameter_list
( "("
) ")"
type_identifier "int"
block
{ "{"
statement_list
return_statement
return "return"
expression_list
int_literal "4096"
} "}"
comment "// NewCallback converts a Go function to a function pointer "...
comment "// This is useful when interoperating with Windows code requ"...
comment "// The argument is expected to be a function with one uintpt"...
function_declaration (+29 nodes collapsed)
comment "// NewCallbackCDecl converts a Go function to a function poi"...
comment "// This is useful when interoperating with Windows code requ"...
comment "// The argument is expected to be a function with one uintpt"...
function_declaration (+29 nodes collapsed)
comment "// windows api calls"
comment "//sys\tGetLastError() (lasterr error)"
comment "//sys\tLoadLibrary(libname string) (handle Handle, err error)"...
comment "//sys\tLoadLibraryEx(libname string, zero Handle, flags uintp"...
comment "//sys\tFreeLibrary(handle Handle) (err error)"
comment "//sys\tGetProcAddress(module Handle, procname string) (proc u"...
comment "//sys\tGetModuleFileName(module Handle, filename *uint16, siz"...
comment "//sys\tGetModuleHandleEx(flags uint32, moduleName *uint16, mo"...
comment "//sys\tSetDefaultDllDirectories(directoryFlags uint32) (err e"...
comment "//sys\tAddDllDirectory(path *uint16) (cookie uintptr, err err"...
comment "//sys\tRemoveDllDirectory(cookie uintptr) (err error) = kerne"...
comment "//sys\tSetDllDirectory(path string) (err error) = kernel32.Se"...
comment "//sys\tGetVersion() (ver uint32, err error)"
comment "//sys\tFormatMessage(flags uint32, msgsrc uintptr, msgid uint"...
comment "//sys\tExitProcess(exitcode uint32)"
comment "//sys\tIsWow64Process(handle Handle, isWow64 *bool) (err erro"...
comment "//sys\tIsWow64Process2(handle Handle, processMachine *uint16,"...
comment "//sys\tCreateFile(name *uint16, access uint32, mode uint32, s"...
comment "//sys\tCreateNamedPipe(name *uint16, flags uint32, pipeMode u"...
comment "//sys\tConnectNamedPipe(pipe Handle, overlapped *Overlapped) "...
comment "//sys\tDisconnectNamedPipe(pipe Handle) (err error)"
comment "//sys GetNamedPipeClientProcessId(pipe Handle, clientProce"...
comment "//sys GetNamedPipeServerProcessId(pipe Handle, serverProce"...
comment "//sys\tGetNamedPipeInfo(pipe Handle, flags *uint32, outSize *"...
comment "//sys\tGetNamedPipeHandleState(pipe Handle, state *uint32, cu"...
comment "//sys\tSetNamedPipeHandleState(pipe Handle, state *uint32, ma"...
comment "//sys\treadFile(handle Handle, buf []byte, done *uint32, over"...
comment "//sys\twriteFile(handle Handle, buf []byte, done *uint32, ove"...
comment "//sys\tGetOverlappedResult(handle Handle, overlapped *Overlap"...
comment "//sys\tSetFilePointer(handle Handle, lowoffset int32, highoff"...
comment "//sys\tCloseHandle(handle Handle) (err error)"
comment "//sys\tGetStdHandle(stdhandle uint32) (handle Handle, err err"...
comment "//sys\tSetStdHandle(stdhandle uint32, handle Handle) (err err"...
comment "//sys\tfindFirstFile1(name *uint16, data *win32finddata1) (ha"...
comment "//sys\tfindNextFile1(handle Handle, data *win32finddata1) (er"...
comment "//sys\tFindClose(handle Handle) (err error)"
comment "//sys\tGetFileInformationByHandle(handle Handle, data *ByHand"...
comment "//sys\tGetFileInformationByHandleEx(handle Handle, class uint"...
comment "//sys\tSetFileInformationByHandle(handle Handle, class uint32"...
comment "//sys\tGetCurrentDirectory(buflen uint32, buf *uint16) (n uin"...
comment "//sys\tSetCurrentDirectory(path *uint16) (err error) = SetCur"...
comment "//sys\tCreateDirectory(path *uint16, sa *SecurityAttributes) "...
comment "//sys\tRemoveDirectory(path *uint16) (err error) = RemoveDire"...
comment "//sys\tDeleteFile(path *uint16) (err error) = DeleteFileW"
comment "//sys\tMoveFile(from *uint16, to *uint16) (err error) = MoveF"...
comment "//sys\tMoveFileEx(from *uint16, to *uint16, flags uint32) (er"...
comment "//sys\tLockFileEx(file Handle, flags uint32, reserved uint32,"...
comment "//sys\tUnlockFileEx(file Handle, reserved uint32, bytesLow ui"...
comment "//sys\tGetComputerName(buf *uint16, n *uint32) (err error) = "...
comment "//sys\tGetComputerNameEx(nametype uint32, buf *uint16, n *uin"...
comment "//sys\tSetEndOfFile(handle Handle) (err error)"
comment "//sys\tSetFileValidData(handle Handle, validDataLength int64)"...
comment "//sys\tGetSystemTimeAsFileTime(time *Filetime)"
comment "//sys\tGetSystemTimePreciseAsFileTime(time *Filetime)"
comment "//sys\tGetTimeZoneInformation(tzi *Timezoneinformation) (rc u"...
comment "//sys\tCreateIoCompletionPort(filehandle Handle, cphandle Han"...
comment "//sys\tGetQueuedCompletionStatus(cphandle Handle, qty *uint32"...
comment "//sys\tPostQueuedCompletionStatus(cphandle Handle, qty uint32"...
comment "//sys\tCancelIo(s Handle) (err error)"
comment "//sys\tCancelIoEx(s Handle, o *Overlapped) (err error)"
comment "//sys\tCreateProcess(appName *uint16, commandLine *uint16, pr"...
comment "//sys\tCreateProcessAsUser(token Token, appName *uint16, comm"...
comment "//sys initializeProcThreadAttributeList(attrlist *ProcThre"...
comment "//sys deleteProcThreadAttributeList(attrlist *ProcThreadAt"...
comment "//sys updateProcThreadAttribute(attrlist *ProcThreadAttrib"...
comment "//sys\tOpenProcess(desiredAccess uint32, inheritHandle bool, "...
comment "//sys\tShellExecute(hwnd Handle, verb *uint16, file *uint16, "...
comment "//sys\tGetWindowThreadProcessId(hwnd HWND, pid *uint32) (tid "...
comment "//sys\tLoadKeyboardLayout(name *uint16, flags uint32) (hkl Ha"...
comment "//sys\tUnloadKeyboardLayout(hkl Handle) (err error) = user32."...
comment "//sys\tGetKeyboardLayout(tid uint32) (hkl Handle) = user32.Ge"...
comment "//sys\tToUnicodeEx(vkey uint32, scancode uint32, keystate *by"...
comment "//sys\tGetShellWindow() (shellWindow HWND) = user32.GetShellW"...
comment "//sys\tMessageBox(hwnd HWND, text *uint16, caption *uint16, b"...
comment "//sys\tExitWindowsEx(flags uint32, reason uint32) (err error)"...
comment "//sys\tshGetKnownFolderPath(id *KNOWNFOLDERID, flags uint32, "...
comment "//sys\tTerminateProcess(handle Handle, exitcode uint32) (err "...
comment "//sys\tGetExitCodeProcess(handle Handle, exitcode *uint32) (e"...
comment "//sys\tgetStartupInfo(startupInfo *StartupInfo) = GetStartupI"...
comment "//sys\tGetProcessTimes(handle Handle, creationTime *Filetime,"...
comment "//sys\tDuplicateHandle(hSourceProcessHandle Handle, hSourceHa"...
comment "//sys\tWaitForSingleObject(handle Handle, waitMilliseconds ui"...
comment "//sys\twaitForMultipleObjects(count uint32, handles uintptr, "...
comment "//sys\tGetTempPath(buflen uint32, buf *uint16) (n uint32, err"...
comment "//sys\tCreatePipe(readhandle *Handle, writehandle *Handle, sa"...
comment "//sys\tGetFileType(filehandle Handle) (n uint32, err error)"
comment "//sys\tCryptAcquireContext(provhandle *Handle, container *uin"...
comment "//sys\tCryptReleaseContext(provhandle Handle, flags uint32) ("...
comment "//sys\tCryptGenRandom(provhandle Handle, buflen uint32, buf *"...
comment "//sys\tGetEnvironmentStrings() (envs *uint16, err error) [fai"...
comment "//sys\tFreeEnvironmentStrings(envs *uint16) (err error) = ker"...
comment "//sys\tGetEnvironmentVariable(name *uint16, buffer *uint16, s"...
comment "//sys\tSetEnvironmentVariable(name *uint16, value *uint16) (e"...
comment "//sys\tExpandEnvironmentStrings(src *uint16, dst *uint16, siz"...
comment "//sys\tCreateEnvironmentBlock(block **uint16, token Token, in"...
comment "//sys\tDestroyEnvironmentBlock(block *uint16) (err error) = u"...
comment "//sys\tgetTickCount64() (ms uint64) = kernel32.GetTickCount64"
comment "//sys GetFileTime(handle Handle, ctime *Filetime, atime *F"...
comment "//sys\tSetFileTime(handle Handle, ctime *Filetime, atime *Fil"...
comment "//sys\tGetFileAttributes(name *uint16) (attrs uint32, err err"...
comment "//sys\tSetFileAttributes(name *uint16, attrs uint32) (err err"...
comment "//sys\tGetFileAttributesEx(name *uint16, level uint32, info *"...
comment "//sys\tGetCommandLine() (cmd *uint16) = kernel32.GetCommandLi"...
comment "//sys\tcommandLineToArgv(cmd *uint16, argc *int32) (argv **ui"...
comment "//sys\tLocalFree(hmem Handle) (handle Handle, err error) [fai"...
comment "//sys\tLocalAlloc(flags uint32, length uint32) (ptr uintptr, "...
comment "//sys\tSetHandleInformation(handle Handle, mask uint32, flags"...
comment "//sys\tFlushFileBuffers(handle Handle) (err error)"
comment "//sys\tGetFullPathName(path *uint16, buflen uint32, buf *uint"...
comment "//sys\tGetLongPathName(path *uint16, buf *uint16, buflen uint"...
comment "//sys\tGetShortPathName(longpath *uint16, shortpath *uint16, "...
comment "//sys\tGetFinalPathNameByHandle(file Handle, filePath *uint16"...
comment "//sys\tCreateFileMapping(fhandle Handle, sa *SecurityAttribut"...
comment "//sys\tMapViewOfFile(handle Handle, access uint32, offsetHigh"...
comment "//sys\tUnmapViewOfFile(addr uintptr) (err error)"
comment "//sys\tFlushViewOfFile(addr uintptr, length uintptr) (err err"...
comment "//sys\tVirtualLock(addr uintptr, length uintptr) (err error)"
comment "//sys\tVirtualUnlock(addr uintptr, length uintptr) (err error"...
comment "//sys\tVirtualAlloc(address uintptr, size uintptr, alloctype "...
comment "//sys\tVirtualFree(address uintptr, size uintptr, freetype ui"...
comment "//sys\tVirtualProtect(address uintptr, size uintptr, newprote"...
comment "//sys\tVirtualProtectEx(process Handle, address uintptr, size"...
comment "//sys\tVirtualQuery(address uintptr, buffer *MemoryBasicInfor"...
comment "//sys\tVirtualQueryEx(process Handle, address uintptr, buffer"...
comment "//sys\tReadProcessMemory(process Handle, baseAddress uintptr,"...
comment "//sys\tWriteProcessMemory(process Handle, baseAddress uintptr"...
comment "//sys\tTransmitFile(s Handle, handle Handle, bytesToWrite uin"...
comment "//sys\tReadDirectoryChanges(handle Handle, buf *byte, buflen "...
comment "//sys\tFindFirstChangeNotification(path string, watchSubtree "...
comment "//sys\tFindNextChangeNotification(handle Handle) (err error)"
comment "//sys\tFindCloseChangeNotification(handle Handle) (err error)"
comment "//sys\tCertOpenSystemStore(hprov Handle, name *uint16) (store"...
comment "//sys\tCertOpenStore(storeProvider uintptr, msgAndCertEncodin"...
comment "//sys\tCertEnumCertificatesInStore(store Handle, prevContext "...
comment "//sys\tCertAddCertificateContextToStore(store Handle, certCon"...
comment "//sys\tCertCloseStore(store Handle, flags uint32) (err error)"...
comment "//sys\tCertDeleteCertificateFromStore(certContext *CertContex"...
comment "//sys\tCertDuplicateCertificateContext(certContext *CertConte"...
comment "//sys\tPFXImportCertStore(pfx *CryptDataBlob, password *uint1"...
comment "//sys\tCertGetCertificateChain(engine Handle, leaf *CertConte"...
comment "//sys\tCertFreeCertificateChain(ctx *CertChainContext) = cryp"...
comment "//sys\tCertCreateCertificateContext(certEncodingType uint32, "...
comment "//sys\tCertFreeCertificateContext(ctx *CertContext) (err erro"...
comment "//sys\tCertVerifyCertificateChainPolicy(policyOID uintptr, ch"...
comment "//sys\tCertGetNameString(certContext *CertContext, nameType u"...
comment "//sys\tCertFindExtension(objId *byte, countExtensions uint32,"...
comment "//sys CertFindCertificateInStore(store Handle, certEncodin"...
comment "//sys CertFindChainInStore(store Handle, certEncodingType "...
comment "//sys CryptAcquireCertificatePrivateKey(cert *CertContext,"...
comment "//sys\tCryptQueryObject(objectType uint32, object unsafe.Poin"...
comment "//sys\tCryptDecodeObject(encodingType uint32, structType *byt"...
comment "//sys\tCryptProtectData(dataIn *DataBlob, name *uint16, optio"...
comment "//sys\tCryptUnprotectData(dataIn *DataBlob, name **uint16, op"...
comment "//sys\tWinVerifyTrustEx(hwnd HWND, actionId *GUID, data *WinT"...
comment "//sys\tRegOpenKeyEx(key Handle, subkey *uint16, options uint3"...
comment "//sys\tRegCloseKey(key Handle) (regerrno error) = advapi32.Re"...
comment "//sys\tRegQueryInfoKey(key Handle, class *uint16, classLen *u"...
comment "//sys\tRegEnumKeyEx(key Handle, index uint32, name *uint16, n"...
comment "//sys\tRegQueryValueEx(key Handle, name *uint16, reserved *ui"...
comment "//sys\tRegNotifyChangeKeyValue(key Handle, watchSubtree bool,"...
comment "//sys\tGetCurrentProcessId() (pid uint32) = kernel32.GetCurre"...
comment "//sys\tProcessIdToSessionId(pid uint32, sessionid *uint32) (e"...
comment "//sys\tClosePseudoConsole(console Handle) = kernel32.ClosePse"...
comment "//sys\tcreatePseudoConsole(size uint32, in Handle, out Handle"...
comment "//sys\tGetConsoleMode(console Handle, mode *uint32) (err erro"...
comment "//sys\tSetConsoleMode(console Handle, mode uint32) (err error"...
comment "//sys\tGetConsoleScreenBufferInfo(console Handle, info *Conso"...
comment "//sys\tsetConsoleCursorPosition(console Handle, position uint"...
comment "//sys\tGetConsoleCP() (cp uint32, err error) = kernel32.GetCo"...
comment "//sys\tGetConsoleOutputCP() (cp uint32, err error) = kernel32"...
comment "//sys\tSetConsoleCP(cp uint32) (err error) = kernel32.SetCons"...
comment "//sys\tSetConsoleOutputCP(cp uint32) (err error) = kernel32.S"...
comment "//sys\tWriteConsole(console Handle, buf *uint16, towrite uint"...
comment "//sys\tReadConsole(console Handle, buf *uint16, toread uint32"...
comment "//sys\tresizePseudoConsole(pconsole Handle, size uint32) (hr "...
comment "//sys\tCreateToolhelp32Snapshot(flags uint32, processId uint3"...
comment "//sys\tModule32First(snapshot Handle, moduleEntry *ModuleEntr"...
comment "//sys\tModule32Next(snapshot Handle, moduleEntry *ModuleEntry"...
comment "//sys\tProcess32First(snapshot Handle, procEntry *ProcessEntr"...
comment "//sys\tProcess32Next(snapshot Handle, procEntry *ProcessEntry"...
comment "//sys\tThread32First(snapshot Handle, threadEntry *ThreadEntr"...
comment "//sys\tThread32Next(snapshot Handle, threadEntry *ThreadEntry"...
comment "//sys\tDeviceIoControl(handle Handle, ioControlCode uint32, i"...
comment "// This function returns 1 byte BOOLEAN rather than the 4 by"...
comment "//sys\tCreateSymbolicLink(symlinkfilename *uint16, targetfile"...
comment "//sys\tCreateHardLink(filename *uint16, existingfilename *uin"...
comment "//sys\tGetCurrentThreadId() (id uint32)"
comment "//sys\tCreateEvent(eventAttrs *SecurityAttributes, manualRese"...
comment "//sys\tCreateEventEx(eventAttrs *SecurityAttributes, name *ui"...
comment "//sys\tOpenEvent(desiredAccess uint32, inheritHandle bool, na"...
comment "//sys\tSetEvent(event Handle) (err error) = kernel32.SetEvent"
comment "//sys\tResetEvent(event Handle) (err error) = kernel32.ResetE"...
comment "//sys\tPulseEvent(event Handle) (err error) = kernel32.PulseE"...
comment "//sys\tCreateMutex(mutexAttrs *SecurityAttributes, initialOwn"...
comment "//sys\tCreateMutexEx(mutexAttrs *SecurityAttributes, name *ui"...
comment "//sys\tOpenMutex(desiredAccess uint32, inheritHandle bool, na"...
comment "//sys\tReleaseMutex(mutex Handle) (err error) = kernel32.Rele"...
comment "//sys\tSleepEx(milliseconds uint32, alertable bool) (ret uint"...
comment "//sys\tCreateJobObject(jobAttr *SecurityAttributes, name *uin"...
comment "//sys\tAssignProcessToJobObject(job Handle, process Handle) ("...
comment "//sys\tTerminateJobObject(job Handle, exitCode uint32) (err e"...
comment "//sys\tSetErrorMode(mode uint32) (ret uint32) = kernel32.SetE"...
comment "//sys\tResumeThread(thread Handle) (ret uint32, err error) [f"...
comment "//sys\tSetPriorityClass(process Handle, priorityClass uint32)"...
comment "//sys\tGetPriorityClass(process Handle) (ret uint32, err erro"...
comment "//sys\tQueryInformationJobObject(job Handle, JobObjectInforma"...
comment "//sys\tSetInformationJobObject(job Handle, JobObjectInformati"...
comment "//sys\tGenerateConsoleCtrlEvent(ctrlEvent uint32, processGrou"...
comment "//sys\tGetProcessId(process Handle) (id uint32, err error)"
comment "//sys\tQueryFullProcessImageName(proc Handle, flags uint32, e"...
comment "//sys\tOpenThread(desiredAccess uint32, inheritHandle bool, t"...
comment "//sys\tSetProcessPriorityBoost(process Handle, disable bool) "...
comment "//sys\tGetProcessWorkingSetSizeEx(hProcess Handle, lpMinimumW"...
comment "//sys\tSetProcessWorkingSetSizeEx(hProcess Handle, dwMinimumW"...
comment "//sys\tClearCommBreak(handle Handle) (err error)"
comment "//sys\tClearCommError(handle Handle, lpErrors *uint32, lpStat"...
comment "//sys\tEscapeCommFunction(handle Handle, dwFunc uint32) (err "...
comment "//sys\tGetCommState(handle Handle, lpDCB *DCB) (err error)"
comment "//sys\tGetCommModemStatus(handle Handle, lpModemStat *uint32)"...
comment "//sys\tGetCommTimeouts(handle Handle, timeouts *CommTimeouts)"...
comment "//sys\tPurgeComm(handle Handle, dwFlags uint32) (err error)"
comment "//sys\tSetCommBreak(handle Handle) (err error)"
comment "//sys\tSetCommMask(handle Handle, dwEvtMask uint32) (err erro"...
comment "//sys\tSetCommState(handle Handle, lpDCB *DCB) (err error)"
comment "//sys\tSetCommTimeouts(handle Handle, timeouts *CommTimeouts)"...
comment "//sys\tSetupComm(handle Handle, dwInQueue uint32, dwOutQueue "...
comment "//sys\tWaitCommEvent(handle Handle, lpEvtMask *uint32, lpOver"...
comment "//sys\tGetActiveProcessorCount(groupNumber uint16) (ret uint3"...
comment "//sys\tGetMaximumProcessorCount(groupNumber uint16) (ret uint"...
comment "//sys\tEnumWindows(enumFunc uintptr, param unsafe.Pointer) (e"...
comment "//sys\tEnumChildWindows(hwnd HWND, enumFunc uintptr, param un"...
comment "//sys\tGetClassName(hwnd HWND, className *uint16, maxCount in"...
comment "//sys\tGetDesktopWindow() (hwnd HWND) = user32.GetDesktopWind"...
comment "//sys\tGetForegroundWindow() (hwnd HWND) = user32.GetForegrou"...
comment "//sys\tIsWindow(hwnd HWND) (isWindow bool) = user32.IsWindow"
comment "//sys\tIsWindowUnicode(hwnd HWND) (isUnicode bool) = user32.I"...
comment "//sys\tIsWindowVisible(hwnd HWND) (isVisible bool) = user32.I"...
comment "//sys\tGetGUIThreadInfo(thread uint32, info *GUIThreadInfo) ("...
comment "//sys\tGetLargePageMinimum() (size uintptr)"
comment "// Volume Management Functions"
comment "//sys\tDefineDosDevice(flags uint32, deviceName *uint16, targ"...
comment "//sys\tDeleteVolumeMountPoint(volumeMountPoint *uint16) (err "...
comment "//sys\tFindFirstVolume(volumeName *uint16, bufferLength uint3"...
comment "//sys\tFindFirstVolumeMountPoint(rootPathName *uint16, volume"...
comment "//sys\tFindNextVolume(findVolume Handle, volumeName *uint16, "...
comment "//sys\tFindNextVolumeMountPoint(findVolumeMountPoint Handle, "...
comment "//sys\tFindVolumeClose(findVolume Handle) (err error)"
comment "//sys\tFindVolumeMountPointClose(findVolumeMountPoint Handle)"...
comment "//sys\tGetDiskFreeSpaceEx(directoryName *uint16, freeBytesAva"...
comment "//sys\tGetDriveType(rootPathName *uint16) (driveType uint32) "...
comment "//sys\tGetLogicalDrives() (drivesBitMask uint32, err error) ["...
comment "//sys\tGetLogicalDriveStrings(bufferLength uint32, buffer *ui"...
comment "//sys\tGetVolumeInformation(rootPathName *uint16, volumeNameB"...
comment "//sys\tGetVolumeInformationByHandle(file Handle, volumeNameBu"...
comment "//sys\tGetVolumeNameForVolumeMountPoint(volumeMountPoint *uin"...
comment "//sys\tGetVolumePathName(fileName *uint16, volumePathName *ui"...
comment "//sys\tGetVolumePathNamesForVolumeName(volumeName *uint16, vo"...
comment "//sys\tQueryDosDevice(deviceName *uint16, targetPath *uint16,"...
comment "//sys\tSetVolumeLabel(rootPathName *uint16, volumeName *uint1"...
comment "//sys\tSetVolumeMountPoint(volumeMountPoint *uint16, volumeNa"...
comment "//sys\tInitiateSystemShutdownEx(machineName *uint16, message "...
comment "//sys\tSetProcessShutdownParameters(level uint32, flags uint3"...
comment "//sys\tGetProcessShutdownParameters(level *uint32, flags *uin"...
comment "//sys\tclsidFromString(lpsz *uint16, pclsid *GUID) (ret error"...
comment "//sys\tstringFromGUID2(rguid *GUID, lpsz *uint16, cchMax int3"...
comment "//sys\tcoCreateGuid(pguid *GUID) (ret error) = ole32.CoCreate"...
comment "//sys\tCoTaskMemFree(address unsafe.Pointer) = ole32.CoTaskMe"...
comment "//sys\tCoInitializeEx(reserved uintptr, coInit uint32) (ret e"...
comment "//sys\tCoUninitialize() = ole32.CoUninitialize"
comment "//sys\tCoGetObject(name *uint16, bindOpts *BIND_OPTS3, guid *"...
comment "//sys\tgetProcessPreferredUILanguages(flags uint32, numLangua"...
comment "//sys\tgetThreadPreferredUILanguages(flags uint32, numLanguag"...
comment "//sys\tgetUserPreferredUILanguages(flags uint32, numLanguages"...
comment "//sys\tgetSystemPreferredUILanguages(flags uint32, numLanguag"...
comment "//sys\tfindResource(module Handle, name uintptr, resType uint"...
comment "//sys\tSizeofResource(module Handle, resInfo Handle) (size ui"...
comment "//sys\tLoadResource(module Handle, resInfo Handle) (resData H"...
comment "//sys\tLockResource(resData Handle) (addr uintptr, err error)"...
comment "// Version APIs"
comment "//sys\tGetFileVersionInfoSize(filename string, zeroHandle *Ha"...
comment "//sys\tGetFileVersionInfo(filename string, handle uint32, buf"...
comment "//sys\tVerQueryValue(block unsafe.Pointer, subBlock string, p"...
comment "// Process Status API (PSAPI)"
comment "//sys\tenumProcesses(processIds *uint32, nSize uint32, bytesR"...
comment "//sys\tEnumProcessModules(process Handle, module *Handle, cb "...
comment "//sys\tEnumProcessModulesEx(process Handle, module *Handle, c"...
comment "//sys\tGetModuleInformation(process Handle, module Handle, mo"...
comment "//sys\tGetModuleFileNameEx(process Handle, module Handle, fil"...
comment "//sys\tGetModuleBaseName(process Handle, module Handle, baseN"...
comment "//sys QueryWorkingSetEx(process Handle, pv uintptr, cb uin"...
comment "// NT Native APIs"
comment "//sys\trtlNtStatusToDosErrorNoTeb(ntstatus NTStatus) (ret sys"...
comment "//sys\trtlGetVersion(info *OsVersionInfoEx) (ntstatus error) "...
comment "//sys\trtlGetNtVersionNumbers(majorVersion *uint32, minorVers"...
comment "//sys\tRtlGetCurrentPeb() (peb *PEB) = ntdll.RtlGetCurrentPeb"
comment "//sys\tRtlInitUnicodeString(destinationString *NTUnicodeStrin"...
comment "//sys\tRtlInitString(destinationString *NTString, sourceStrin"...
comment "//sys\tNtCreateFile(handle *Handle, access uint32, oa *OBJECT"...
comment "//sys\tNtCreateNamedPipeFile(pipe *Handle, access uint32, oa "...
comment "//sys\tNtSetInformationFile(handle Handle, iosb *IO_STATUS_BL"...
comment "//sys\tRtlDosPathNameToNtPathName(dosName *uint16, ntName *NT"...
comment "//sys\tRtlDosPathNameToRelativeNtPathName(dosName *uint16, nt"...
comment "//sys\tRtlDefaultNpAcl(acl **ACL) (ntstatus error) = ntdll.Rt"...
comment "//sys\tNtQueryInformationProcess(proc Handle, procInfoClass i"...
comment "//sys\tNtSetInformationProcess(proc Handle, procInfoClass int"...
comment "//sys\tNtQuerySystemInformation(sysInfoClass int32, sysInfo u"...
comment "//sys\tNtSetSystemInformation(sysInfoClass int32, sysInfo uns"...
comment "//sys\tRtlAddFunctionTable(functionTable *RUNTIME_FUNCTION, e"...
comment "//sys\tRtlDeleteFunctionTable(functionTable *RUNTIME_FUNCTION"...
comment "// Desktop Window Manager API (Dwmapi)"
comment "//sys\tDwmGetWindowAttribute(hwnd HWND, attribute uint32, val"...
comment "//sys\tDwmSetWindowAttribute(hwnd HWND, attribute uint32, val"...
comment "// Windows Multimedia API"
comment "//sys TimeBeginPeriod (period uint32) (err error) [failretva"...
comment "//sys TimeEndPeriod (period uint32) (err error) [failretval "...
comment "// syscall interface implementation for other packages"
comment "// GetCurrentProcess returns the handle for the current proc"...
comment "// It is a pseudo handle that does not need to be closed."
comment "// The returned error is always nil."
comment "//"
comment "// Deprecated: use CurrentProcess for the same Handle withou"...
comment "// error."
function_declaration (+28 nodes collapsed)
comment "// CurrentProcess returns the handle for the current process"...
comment "// It is a pseudo handle that does not need to be closed."
function_declaration (+30 nodes collapsed)
comment "// GetCurrentThread returns the handle for the current threa"...
comment "// It is a pseudo handle that does not need to be closed."
comment "// The returned error is always nil."
comment "//"
comment "// Deprecated: use CurrentThread for the same Handle without"...
comment "// error."
function_declaration (+28 nodes collapsed)
comment "// CurrentThread returns the handle for the current thread."
comment "// It is a pseudo handle that does not need to be closed."
function_declaration (+30 nodes collapsed)
comment "// GetProcAddressByOrdinal retrieves the address of the expo"...
comment "// function from module by ordinal."
function_declaration (+99 nodes collapsed)
function_declaration (+25 nodes collapsed)
function_declaration (+55 nodes collapsed)
function_declaration (+403 nodes collapsed)
function_declaration (+98 nodes collapsed)
function_declaration (+105 nodes collapsed)
function_declaration (+120 nodes collapsed)
function_declaration (+123 nodes collapsed)
var_declaration
var "var"
var_spec
identifier "ioSync"
type_identifier "int64"
function_declaration (+194 nodes collapsed)
function_declaration (+28 nodes collapsed)
var_declaration (+35 nodes collapsed)
function_declaration (+36 nodes collapsed)
const_declaration
const "const"
const_spec
identifier "ImplementsGetwd"
= "="
expression_list
true "true"
function_declaration (+110 nodes collapsed)
function_declaration (+55 nodes collapsed)
function_declaration (+61 nodes collapsed)
function_declaration (+55 nodes collapsed)
function_declaration (+55 nodes collapsed)
function_declaration (+88 nodes collapsed)
function_declaration (+111 nodes collapsed)
function_declaration (+36 nodes collapsed)
function_declaration (+97 nodes collapsed)
function_declaration (+59 nodes collapsed)
function_declaration (+114 nodes collapsed)
function_declaration (+185 nodes collapsed)
function_declaration (+181 nodes collapsed)
function_declaration (+28 nodes collapsed)
function_declaration (+118 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+109 nodes collapsed)
comment "// net api calls"
const_declaration
const "const"
const_spec
identifier "socket_error"
= "="
expression_list
call_expression
identifier "uintptr"
argument_list
( "("
unary_expression
^ "^"
call_expression
identifier "uint32"
argument_list
( "("
int_literal "0"
) ")"
) ")"
comment "//sys\tWSAStartup(verreq uint32, data *WSAData) (sockerr erro"...
comment "//sys\tWSACleanup() (err error) [failretval==socket_error] = "...
comment "//sys\tWSAIoctl(s Handle, iocc uint32, inbuf *byte, cbif uint"...
comment "//sys\tWSALookupServiceBegin(querySet *WSAQUERYSET, flags uin"...
comment "//sys\tWSALookupServiceNext(handle Handle, flags uint32, size"...
comment "//sys\tWSALookupServiceEnd(handle Handle) (err error) [failre"...
comment "//sys\tsocket(af int32, typ int32, protocol int32) (handle Ha"...
comment "//sys\tsendto(s Handle, buf []byte, flags int32, to unsafe.Po"...
comment "//sys\trecvfrom(s Handle, buf []byte, flags int32, from *RawS"...
comment "//sys\tSetsockopt(s Handle, level int32, optname int32, optva"...
comment "//sys\tGetsockopt(s Handle, level int32, optname int32, optva"...
comment "//sys\tbind(s Handle, name unsafe.Pointer, namelen int32) (er"...
comment "//sys\tconnect(s Handle, name unsafe.Pointer, namelen int32) "...
comment "//sys\tgetsockname(s Handle, rsa *RawSockaddrAny, addrlen *in"...
comment "//sys\tgetpeername(s Handle, rsa *RawSockaddrAny, addrlen *in"...
comment "//sys\tlisten(s Handle, backlog int32) (err error) [failretva"...
comment "//sys\tshutdown(s Handle, how int32) (err error) [failretval="...
comment "//sys\tClosesocket(s Handle) (err error) [failretval==socket_"...
comment "//sys\tAcceptEx(ls Handle, as Handle, buf *byte, rxdatalen ui"...
comment "//sys\tGetAcceptExSockaddrs(buf *byte, rxdatalen uint32, ladd"...
comment "//sys\tWSARecv(s Handle, bufs *WSABuf, bufcnt uint32, recvd *"...
comment "//sys\tWSASend(s Handle, bufs *WSABuf, bufcnt uint32, sent *u"...
comment "//sys\tWSARecvFrom(s Handle, bufs *WSABuf, bufcnt uint32, rec"...
comment "//sys\tWSASendTo(s Handle, bufs *WSABuf, bufcnt uint32, sent "...
comment "//sys\tWSASocket(af int32, typ int32, protocol int32, protoIn"...
comment "//sys\tGetHostByName(name string) (h *Hostent, err error) [fa"...
comment "//sys\tGetServByName(name string, proto string) (s *Servent, "...
comment "//sys\tNtohs(netshort uint16) (u uint16) = ws2_32.ntohs"
comment "//sys\tGetProtoByName(name string) (p *Protoent, err error) ["...
comment "//sys\tDnsQuery(name string, qtype uint16, options uint32, ex"...
comment "//sys\tDnsRecordListFree(rl *DNSRecord, freetype uint32) = dn"...
comment "//sys\tDnsNameCompare(name1 *uint16, name2 *uint16) (same boo"...
comment "//sys\tGetAddrInfoW(nodename *uint16, servicename *uint16, hi"...
comment "//sys\tFreeAddrInfoW(addrinfo *AddrinfoW) = ws2_32.FreeAddrIn"...
comment "//sys\tGetIfEntry(pIfRow *MibIfRow) (errcode error) = iphlpap"...
comment "//sys\tGetAdaptersInfo(ai *IpAdapterInfo, ol *uint32) (errcod"...
comment "//sys\tSetFileCompletionNotificationModes(handle Handle, flag"...
comment "//sys\tWSAEnumProtocols(protocols *int32, protocolBuffer *WSA"...
comment "//sys\tWSAGetOverlappedResult(h Handle, o *Overlapped, bytes "...
comment "//sys\tGetAdaptersAddresses(family uint32, flags uint32, rese"...
comment "//sys\tGetACP() (acp uint32) = kernel32.GetACP"
comment "//sys\tMultiByteToWideChar(codePage uint32, dwFlags uint32, s"...
comment "//sys\tgetBestInterfaceEx(sockaddr unsafe.Pointer, pdwBestIfI"...
comment "//sys GetIfEntry2Ex(level uint32, row *MibIfRow2) (errcode"...
comment "//sys GetUnicastIpAddressEntry(row *MibUnicastIpAddressRow"...
comment "//sys NotifyIpInterfaceChange(family uint16, callback uint"...
comment "//sys NotifyUnicastIpAddressChange(family uint16, callback"...
comment "//sys CancelMibChangeNotify2(notificationHandle Handle) (e"...
comment "// For testing: clients can set this flag to force"
comment "// creation of IPv6 sockets to return EAFNOSUPPORT."
var_declaration
var "var"
var_spec
identifier "SocketDisableIPv6"
type_identifier "bool"
type_declaration (+30 nodes collapsed)
type_declaration (+29 nodes collapsed)
type_declaration
type "type"
type_spec
type_identifier "RawSockaddr"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Family"
type_identifier "uint16"
field_declaration
field_identifier "Data"
array_type
[ "["
int_literal "14"
] "]"
type_identifier "int8"
} "}"
type_declaration
type "type"
type_spec
type_identifier "RawSockaddrAny"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Addr"
type_identifier "RawSockaddr"
field_declaration
field_identifier "Pad"
array_type
[ "["
int_literal "100"
] "]"
type_identifier "int8"
} "}"
type_declaration (+31 nodes collapsed)
type_declaration (+22 nodes collapsed)
method_declaration (+203 nodes collapsed)
type_declaration (+25 nodes collapsed)
method_declaration (+218 nodes collapsed)
type_declaration
type "type"
type_spec
type_identifier "RawSockaddrUnix"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Family"
type_identifier "uint16"
field_declaration
field_identifier "Path"
array_type
[ "["
identifier "UNIX_PATH_MAX"
] "]"
type_identifier "int8"
} "}"
type_declaration
type "type"
type_spec
type_identifier "SockaddrUnix"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Name"
type_identifier "string"
field_declaration
field_identifier "raw"
type_identifier "RawSockaddrUnix"
} "}"
method_declaration (+308 nodes collapsed)
type_declaration (+37 nodes collapsed)
type_declaration (+21 nodes collapsed)
method_declaration (+225 nodes collapsed)
method_declaration (+484 nodes collapsed)
function_declaration (+77 nodes collapsed)
function_declaration (+100 nodes collapsed)
function_declaration (+67 nodes collapsed)
function_declaration (+67 nodes collapsed)
function_declaration (+67 nodes collapsed)
function_declaration (+90 nodes collapsed)
function_declaration (+90 nodes collapsed)
function_declaration (+39 nodes collapsed)
function_declaration (+39 nodes collapsed)
function_declaration (+152 nodes collapsed)
function_declaration (+22 nodes collapsed)
var_declaration (+21 nodes collapsed)
function_declaration (+196 nodes collapsed)
function_declaration (+199 nodes collapsed)
function_declaration (+137 nodes collapsed)
var_declaration (+24 nodes collapsed)
function_declaration (+315 nodes collapsed)
function_declaration (+188 nodes collapsed)
function_declaration (+179 nodes collapsed)
comment "// Invented structures to support what package os expects."
type_declaration (+21 nodes collapsed)
type_declaration
type "type"
type_spec
type_identifier "WaitStatus"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "ExitCode"
type_identifier "uint32"
} "}"
method_declaration (+21 nodes collapsed)
method_declaration (+29 nodes collapsed)
method_declaration (+23 nodes collapsed)
method_declaration (+21 nodes collapsed)
method_declaration (+21 nodes collapsed)
method_declaration (+21 nodes collapsed)
method_declaration (+23 nodes collapsed)
method_declaration (+21 nodes collapsed)
method_declaration (+23 nodes collapsed)
comment "// Timespec is an invented structure on Windows, but here fo"...
comment "// consistency with the corresponding package for other oper"...
type_declaration
type "type"
type_spec
type_identifier "Timespec"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Sec"
type_identifier "int64"
field_declaration
field_identifier "Nsec"
type_identifier "int64"
} "}"
function_declaration (+40 nodes collapsed)
function_declaration (+45 nodes collapsed)
comment "// TODO(brainman): fix all needed for net"
function_declaration (+38 nodes collapsed)
function_declaration (+132 nodes collapsed)
function_declaration (+87 nodes collapsed)
function_declaration (+38 nodes collapsed)
comment "// The Linger struct is wrong but we only noticed after Go 1"...
comment "// sysLinger is the real system call structure."
comment "// BUG(brainman): The definition of Linger is not appropriat"...
comment "// with Setsockopt and Getsockopt."
comment "// Use SetsockoptLinger instead."
type_declaration
type "type"
type_spec
type_identifier "Linger"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Onoff"
type_identifier "int32"
field_declaration
field_identifier "Linger"
type_identifier "int32"
} "}"
type_declaration
type "type"
type_spec
type_identifier "sysLinger"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Onoff"
type_identifier "uint16"
field_declaration
field_identifier "Linger"
type_identifier "uint16"
} "}"
type_declaration (+25 nodes collapsed)
type_declaration
type "type"
type_spec
type_identifier "IPv6Mreq"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Multiaddr"
array_type
[ "["
int_literal "16"
] "]"
type_identifier "byte"
comment "/* in6_addr */"
field_declaration
field_identifier "Interface"
type_identifier "uint32"
} "}"
function_declaration (+119 nodes collapsed)
function_declaration (+130 nodes collapsed)
function_declaration (+84 nodes collapsed)
function_declaration (+91 nodes collapsed)
function_declaration (+38 nodes collapsed)
function_declaration (+91 nodes collapsed)
function_declaration (+29 nodes collapsed)
function_declaration (+84 nodes collapsed)
function_declaration (+68 nodes collapsed)
function_declaration (+184 nodes collapsed)
function_declaration (+61 nodes collapsed)
comment "// TODO(brainman): fix all needed for os"
function_declaration (+26 nodes collapsed)
function_declaration (+28 nodes collapsed)
function_declaration (+28 nodes collapsed)
function_declaration (+30 nodes collapsed)
function_declaration (+34 nodes collapsed)
function_declaration (+34 nodes collapsed)
function_declaration (+34 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+32 nodes collapsed)
type_declaration
type "type"
type_spec
type_identifier "Signal"
type_identifier "int"
method_declaration
func "func"
parameter_list
( "("
parameter_declaration
identifier "s"
type_identifier "Signal"
) ")"
field_identifier "Signal"
parameter_list
( "("
) ")"
block
{ "{"
} "}"
method_declaration (+89 nodes collapsed)
function_declaration (+22 nodes collapsed)
comment "// Readlink returns the destination of the named symbolic li"...
function_declaration (+475 nodes collapsed)
comment "// GUIDFromString parses a string in the form of"
comment "// \"{XXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}\" into a GUID."
function_declaration (+100 nodes collapsed)
comment "// GenerateGUID creates a new random GUID."
function_declaration (+63 nodes collapsed)
comment "// String returns the canonical string form of the GUID,"
comment "// in the form of \"{XXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}\"."
method_declaration (+100 nodes collapsed)
comment "// KnownFolderPath returns a well-known folder path for the "...
comment "// the FOLDERID_ constants, and chosen and optionally create"...
function_declaration (+46 nodes collapsed)
comment "// KnownFolderPath returns a well-known folder path for the "...
comment "// the FOLDERID_ constants, and chosen and optionally create"...
method_declaration (+104 nodes collapsed)
comment "// RtlGetVersion returns the version of the underlying opera"...
comment "// manifest semantics but is affected by the application com"...
function_declaration (+68 nodes collapsed)
comment "// RtlGetNtVersionNumbers returns the version of the underly"...
comment "// ignoring manifest semantics and the application compatibi"...
function_declaration (+45 nodes collapsed)
comment "// GetProcessPreferredUILanguages retrieves the process pref"...
function_declaration (+35 nodes collapsed)
comment "// GetThreadPreferredUILanguages retrieves the thread prefer"...
function_declaration (+35 nodes collapsed)
comment "// GetUserPreferredUILanguages retrieves information about t"...
function_declaration (+35 nodes collapsed)
comment "// GetSystemPreferredUILanguages retrieves the system prefer"...
function_declaration (+35 nodes collapsed)
function_declaration (+330 nodes collapsed)
function_declaration (+54 nodes collapsed)
function_declaration (+27 nodes collapsed)
method_declaration (+29 nodes collapsed)
function_declaration (+36 nodes collapsed)
method_declaration (+180 nodes collapsed)
comment "// NewNTUnicodeString returns a new NTUnicodeString structur"...
comment "// NT APIs that work over the NTUnicodeString type. Note tha"...
comment "// do not use NTUnicodeString, and instead UTF16PtrFromStrin"...
comment "// the more common *uint16 string type."
function_declaration (+114 nodes collapsed)
comment "// Slice returns a uint16 slice that aliases the data in the"...
method_declaration
func "func"
parameter_list
( "("
parameter_declaration
identifier "s"
pointer_type
* "*"
type_identifier "NTUnicodeString"
) ")"
field_identifier "Slice"
parameter_list
( "("
) ")"
slice_type
[ "["
] "]"
type_identifier "uint16"
block
{ "{"
statement_list
short_var_declaration
expression_list
identifier "slice"
:= ":="
expression_list
call_expression
selector_expression
identifier "unsafe"
. "."
field_identifier "Slice"
argument_list
( "("
selector_expression
identifier "s"
. "."
field_identifier "Buffer"
, ","
selector_expression
identifier "s"
. "."
field_identifier "MaximumLength"
) ")"
return_statement
return "return"
expression_list
slice_expression
identifier "slice"
[ "["
: ":"
selector_expression
identifier "s"
. "."
field_identifier "Length"
] "]"
} "}"
method_declaration (+35 nodes collapsed)
comment "// NewNTString returns a new NTString structure for use with"...
comment "// NT APIs that work over the NTString type. Note that most "...
comment "// do not use NTString, and instead UTF16PtrFromString shoul"...
comment "// the more common *uint16 string type."
function_declaration (+76 nodes collapsed)
comment "// Slice returns a byte slice that aliases the data in the N"...
method_declaration (+56 nodes collapsed)
method_declaration (+35 nodes collapsed)
comment "// FindResource resolves a resource of the given name and re"...
function_declaration (+295 nodes collapsed)
function_declaration (+143 nodes collapsed)
comment "// PSAPI_WORKING_SET_EX_BLOCK contains extended working set "...
type_declaration
type "type"
type_spec
type_identifier "PSAPI_WORKING_SET_EX_BLOCK"
type_identifier "uint64"
comment "// Valid returns the validity of this page."
comment "// If this bit is 1, the subsequent members are valid; other"...
method_declaration (+30 nodes collapsed)
comment "// ShareCount is the number of processes that share this pag"...
method_declaration (+31 nodes collapsed)
comment "// Win32Protection is the memory protection attributes of th"...
comment "// https://docs.microsoft.com/en-us/windows/win32/memory/mem"...
method_declaration (+31 nodes collapsed)
comment "// Shared returns the shared status of this page."
comment "// If this bit is 1, the page can be shared."
method_declaration (+36 nodes collapsed)
comment "// Node is the NUMA node. The maximum value of this member i"...
method_declaration (+31 nodes collapsed)
comment "// Locked returns the locked status of this page."
comment "// If this bit is 1, the virtual page is locked in physical "...
method_declaration (+36 nodes collapsed)
comment "// LargePage returns the large page status of this page."
comment "// If this bit is 1, the page is a large page."
method_declaration (+36 nodes collapsed)
comment "// Bad returns the bad status of this page."
comment "// If this bit is 1, the page is has been reported as bad."
method_declaration (+36 nodes collapsed)
comment "// intField extracts an integer field in the PSAPI_WORKING_S"...
method_declaration (+85 nodes collapsed)
comment "// PSAPI_WORKING_SET_EX_INFORMATION contains extended workin"...
type_declaration
type "type"
type_spec
type_identifier "PSAPI_WORKING_SET_EX_INFORMATION"
struct_type
struct "struct"
field_declaration_list
{ "{"
comment "// The virtual address."
field_declaration
field_identifier "VirtualAddress"
type_identifier "Pointer"
comment "// A PSAPI_WORKING_SET_EX_BLOCK union that indicates the att"...
field_declaration
field_identifier "VirtualAttributes"
type_identifier "PSAPI_WORKING_SET_EX_BLOCK"
} "}"
comment "// CreatePseudoConsole creates a windows pseudo console."
function_declaration (+76 nodes collapsed)
comment "// ResizePseudoConsole resizes the internal buffers of the p"...
function_declaration (+56 nodes collapsed)
comment "// DCB constants. See https://learn.microsoft.com/en-us/wind"...
const_declaration (+149 nodes collapsed)
comment "// EscapeCommFunction constants. See https://learn.microsoft"...
const_declaration (+44 nodes collapsed)
comment "// PurgeComm constants. See https://learn.microsoft.com/en-u"...
const_declaration (+24 nodes collapsed)
comment "// SetCommMask constants. See https://learn.microsoft.com/en"...
const_declaration (+49 nodes collapsed)

After

source_file
comment "// Copyright 2009 The Go Authors. All rights reserved."
comment "// Use of this source code is governed by a BSD-style"
comment "// license that can be found in the LICENSE file."
comment "// Windows system calls."
package_clause
package "package"
package_identifier "windows"
import_declaration (+46 nodes collapsed)
type_declaration
type "type"
( "("
type_spec
type_identifier "Handle"
type_identifier "uintptr"
type_spec
type_identifier "HWND"
type_identifier "uintptr"
) ")"
const_declaration (+203 nodes collapsed)
comment "// StringToUTF16 is deprecated. Use UTF16FromString instead."
comment "// If s contains a NUL byte this function panics instead of"
comment "// returning an error."
function_declaration (+54 nodes collapsed)
comment "// UTF16FromString returns the UTF-16 encoding of the UTF-8 "...
comment "// s, with a terminating NUL added. If s contains a NUL byte"...
comment "// location, it returns (nil, syscall.EINVAL)."
function_declaration (+36 nodes collapsed)
comment "// UTF16ToString returns the UTF-8 encoding of the UTF-16 se"...
comment "// with a terminating NUL and any bytes after the NUL remove"...
function_declaration (+29 nodes collapsed)
comment "// StringToUTF16Ptr is deprecated. Use UTF16PtrFromString in"...
comment "// If s contains a NUL byte this function panics instead of"
comment "// returning an error."
function_declaration (+31 nodes collapsed)
comment "// UTF16PtrFromString returns pointer to the UTF-16 encoding"...
comment "// the UTF-8 string s, with a terminating NUL added. If s"
comment "// contains a NUL byte at any location, it returns (nil, sys"...
function_declaration (+64 nodes collapsed)
comment "// UTF16PtrToString takes a pointer to a UTF-16 sequence and"...
comment "// If the pointer is nil, it returns the empty string. It as"...
comment "// at a zero word; if the zero word is not present, the prog"...
function_declaration (+150 nodes collapsed)
function_declaration
func "func"
identifier "Getpagesize"
parameter_list
( "("
) ")"
type_identifier "int"
block
{ "{"
statement_list
return_statement
return "return"
expression_list
int_literal "4096"
} "}"
comment "// NewCallback converts a Go function to a function pointer "...
comment "// This is useful when interoperating with Windows code requ"...
comment "// The argument is expected to be a function with one uintpt"...
function_declaration (+29 nodes collapsed)
comment "// NewCallbackCDecl converts a Go function to a function poi"...
comment "// This is useful when interoperating with Windows code requ"...
comment "// The argument is expected to be a function with one uintpt"...
function_declaration (+29 nodes collapsed)
comment "// windows api calls"
comment "//sys\tGetLastError() (lasterr error)"
comment "//sys\tLoadLibrary(libname string) (handle Handle, err error)"...
comment "//sys\tLoadLibraryEx(libname string, zero Handle, flags uintp"...
comment "//sys\tFreeLibrary(handle Handle) (err error)"
comment "//sys\tGetProcAddress(module Handle, procname string) (proc u"...
comment "//sys\tGetModuleFileName(module Handle, filename *uint16, siz"...
comment "//sys\tGetModuleHandleEx(flags uint32, moduleName *uint16, mo"...
comment "//sys\tSetDefaultDllDirectories(directoryFlags uint32) (err e"...
comment "//sys\tAddDllDirectory(path *uint16) (cookie uintptr, err err"...
comment "//sys\tRemoveDllDirectory(cookie uintptr) (err error) = kerne"...
comment "//sys\tSetDllDirectory(path string) (err error) = kernel32.Se"...
comment "//sys\tGetVersion() (ver uint32, err error)"
comment "//sys\tFormatMessage(flags uint32, msgsrc uintptr, msgid uint"...
comment "//sys\tExitProcess(exitcode uint32)"
comment "//sys\tIsWow64Process(handle Handle, isWow64 *bool) (err erro"...
comment "//sys\tIsWow64Process2(handle Handle, processMachine *uint16,"...
comment "//sys\tCreateFile(name *uint16, access uint32, mode uint32, s"...
comment "//sys\tCreateNamedPipe(name *uint16, flags uint32, pipeMode u"...
comment "//sys\tConnectNamedPipe(pipe Handle, overlapped *Overlapped) "...
comment "//sys\tDisconnectNamedPipe(pipe Handle) (err error)"
comment "//sys GetNamedPipeClientProcessId(pipe Handle, clientProce"...
comment "//sys GetNamedPipeServerProcessId(pipe Handle, serverProce"...
comment "//sys\tGetNamedPipeInfo(pipe Handle, flags *uint32, outSize *"...
comment "//sys\tGetNamedPipeHandleState(pipe Handle, state *uint32, cu"...
comment "//sys\tSetNamedPipeHandleState(pipe Handle, state *uint32, ma"...
comment "//sys\treadFile(handle Handle, buf []byte, done *uint32, over"...
comment "//sys\twriteFile(handle Handle, buf []byte, done *uint32, ove"...
comment "//sys\tGetOverlappedResult(handle Handle, overlapped *Overlap"...
comment "//sys\tSetFilePointer(handle Handle, lowoffset int32, highoff"...
comment "//sys\tCloseHandle(handle Handle) (err error)"
comment "//sys\tGetStdHandle(stdhandle uint32) (handle Handle, err err"...
comment "//sys\tSetStdHandle(stdhandle uint32, handle Handle) (err err"...
comment "//sys\tfindFirstFile1(name *uint16, data *win32finddata1) (ha"...
comment "//sys\tfindNextFile1(handle Handle, data *win32finddata1) (er"...
comment "//sys\tFindClose(handle Handle) (err error)"
comment "//sys\tGetFileInformationByHandle(handle Handle, data *ByHand"...
comment "//sys\tGetFileInformationByHandleEx(handle Handle, class uint"...
comment "//sys\tSetFileInformationByHandle(handle Handle, class uint32"...
comment "//sys\tGetCurrentDirectory(buflen uint32, buf *uint16) (n uin"...
comment "//sys\tSetCurrentDirectory(path *uint16) (err error) = SetCur"...
comment "//sys\tCreateDirectory(path *uint16, sa *SecurityAttributes) "...
comment "//sys\tRemoveDirectory(path *uint16) (err error) = RemoveDire"...
comment "//sys\tDeleteFile(path *uint16) (err error) = DeleteFileW"
comment "//sys\tMoveFile(from *uint16, to *uint16) (err error) = MoveF"...
comment "//sys\tMoveFileEx(from *uint16, to *uint16, flags uint32) (er"...
comment "//sys\tLockFileEx(file Handle, flags uint32, reserved uint32,"...
comment "//sys\tUnlockFileEx(file Handle, reserved uint32, bytesLow ui"...
comment "//sys\tGetComputerName(buf *uint16, n *uint32) (err error) = "...
comment "//sys\tGetComputerNameEx(nametype uint32, buf *uint16, n *uin"...
comment "//sys\tSetEndOfFile(handle Handle) (err error)"
comment "//sys\tSetFileValidData(handle Handle, validDataLength int64)"...
comment "//sys\tGetSystemTimeAsFileTime(time *Filetime)"
comment "//sys\tGetSystemTimePreciseAsFileTime(time *Filetime)"
comment "//sys\tGetTimeZoneInformation(tzi *Timezoneinformation) (rc u"...
comment "//sys\tCreateIoCompletionPort(filehandle Handle, cphandle Han"...
comment "//sys\tGetQueuedCompletionStatus(cphandle Handle, qty *uint32"...
comment "//sys\tPostQueuedCompletionStatus(cphandle Handle, qty uint32"...
comment "//sys\tCancelIo(s Handle) (err error)"
comment "//sys\tCancelIoEx(s Handle, o *Overlapped) (err error)"
comment "//sys\tCreateProcess(appName *uint16, commandLine *uint16, pr"...
comment "//sys\tCreateProcessAsUser(token Token, appName *uint16, comm"...
comment "//sys initializeProcThreadAttributeList(attrlist *ProcThre"...
comment "//sys deleteProcThreadAttributeList(attrlist *ProcThreadAt"...
comment "//sys updateProcThreadAttribute(attrlist *ProcThreadAttrib"...
comment "//sys\tOpenProcess(desiredAccess uint32, inheritHandle bool, "...
comment "//sys\tShellExecute(hwnd Handle, verb *uint16, file *uint16, "...
comment "//sys\tGetWindowThreadProcessId(hwnd HWND, pid *uint32) (tid "...
comment "//sys\tLoadKeyboardLayout(name *uint16, flags uint32) (hkl Ha"...
comment "//sys\tUnloadKeyboardLayout(hkl Handle) (err error) = user32."...
comment "//sys\tGetKeyboardLayout(tid uint32) (hkl Handle) = user32.Ge"...
comment "//sys\tToUnicodeEx(vkey uint32, scancode uint32, keystate *by"...
comment "//sys\tGetShellWindow() (shellWindow HWND) = user32.GetShellW"...
comment "//sys\tMessageBox(hwnd HWND, text *uint16, caption *uint16, b"...
comment "//sys\tExitWindowsEx(flags uint32, reason uint32) (err error)"...
comment "//sys\tshGetKnownFolderPath(id *KNOWNFOLDERID, flags uint32, "...
comment "//sys\tTerminateProcess(handle Handle, exitcode uint32) (err "...
comment "//sys\tGetExitCodeProcess(handle Handle, exitcode *uint32) (e"...
comment "//sys\tgetStartupInfo(startupInfo *StartupInfo) = GetStartupI"...
comment "//sys\tGetProcessTimes(handle Handle, creationTime *Filetime,"...
comment "//sys\tDuplicateHandle(hSourceProcessHandle Handle, hSourceHa"...
comment "//sys\tWaitForSingleObject(handle Handle, waitMilliseconds ui"...
comment "//sys\twaitForMultipleObjects(count uint32, handles uintptr, "...
comment "//sys\tGetTempPath(buflen uint32, buf *uint16) (n uint32, err"...
comment "//sys\tCreatePipe(readhandle *Handle, writehandle *Handle, sa"...
comment "//sys\tGetFileType(filehandle Handle) (n uint32, err error)"
comment "//sys\tCryptAcquireContext(provhandle *Handle, container *uin"...
comment "//sys\tCryptReleaseContext(provhandle Handle, flags uint32) ("...
comment "//sys\tCryptGenRandom(provhandle Handle, buflen uint32, buf *"...
comment "//sys\tGetEnvironmentStrings() (envs *uint16, err error) [fai"...
comment "//sys\tFreeEnvironmentStrings(envs *uint16) (err error) = ker"...
comment "//sys\tGetEnvironmentVariable(name *uint16, buffer *uint16, s"...
comment "//sys\tSetEnvironmentVariable(name *uint16, value *uint16) (e"...
comment "//sys\tExpandEnvironmentStrings(src *uint16, dst *uint16, siz"...
comment "//sys\tCreateEnvironmentBlock(block **uint16, token Token, in"...
comment "//sys\tDestroyEnvironmentBlock(block *uint16) (err error) = u"...
comment "//sys\tgetTickCount64() (ms uint64) = kernel32.GetTickCount64"
comment "//sys GetFileTime(handle Handle, ctime *Filetime, atime *F"...
comment "//sys\tSetFileTime(handle Handle, ctime *Filetime, atime *Fil"...
comment "//sys\tGetFileAttributes(name *uint16) (attrs uint32, err err"...
comment "//sys\tSetFileAttributes(name *uint16, attrs uint32) (err err"...
comment "//sys\tGetFileAttributesEx(name *uint16, level uint32, info *"...
comment "//sys\tGetCommandLine() (cmd *uint16) = kernel32.GetCommandLi"...
comment "//sys\tcommandLineToArgv(cmd *uint16, argc *int32) (argv **ui"...
comment "//sys\tLocalFree(hmem Handle) (handle Handle, err error) [fai"...
comment "//sys\tLocalAlloc(flags uint32, length uint32) (ptr uintptr, "...
comment "//sys\tSetHandleInformation(handle Handle, mask uint32, flags"...
comment "//sys\tFlushFileBuffers(handle Handle) (err error)"
comment "//sys\tGetFullPathName(path *uint16, buflen uint32, buf *uint"...
comment "//sys\tGetLongPathName(path *uint16, buf *uint16, buflen uint"...
comment "//sys\tGetShortPathName(longpath *uint16, shortpath *uint16, "...
comment "//sys\tGetFinalPathNameByHandle(file Handle, filePath *uint16"...
comment "//sys\tCreateFileMapping(fhandle Handle, sa *SecurityAttribut"...
comment "//sys\tMapViewOfFile(handle Handle, access uint32, offsetHigh"...
comment "//sys\tUnmapViewOfFile(addr uintptr) (err error)"
comment "//sys\tFlushViewOfFile(addr uintptr, length uintptr) (err err"...
comment "//sys\tVirtualLock(addr uintptr, length uintptr) (err error)"
comment "//sys\tVirtualUnlock(addr uintptr, length uintptr) (err error"...
comment "//sys\tVirtualAlloc(address uintptr, size uintptr, alloctype "...
comment "//sys\tVirtualFree(address uintptr, size uintptr, freetype ui"...
comment "//sys\tVirtualProtect(address uintptr, size uintptr, newprote"...
comment "//sys\tVirtualProtectEx(process Handle, address uintptr, size"...
comment "//sys\tVirtualQuery(address uintptr, buffer *MemoryBasicInfor"...
comment "//sys\tVirtualQueryEx(process Handle, address uintptr, buffer"...
comment "//sys\tReadProcessMemory(process Handle, baseAddress uintptr,"...
comment "//sys\tWriteProcessMemory(process Handle, baseAddress uintptr"...
comment "//sys\tTransmitFile(s Handle, handle Handle, bytesToWrite uin"...
comment "//sys\tReadDirectoryChanges(handle Handle, buf *byte, buflen "...
comment "//sys\tFindFirstChangeNotification(path string, watchSubtree "...
comment "//sys\tFindNextChangeNotification(handle Handle) (err error)"
comment "//sys\tFindCloseChangeNotification(handle Handle) (err error)"
comment "//sys\tCertOpenSystemStore(hprov Handle, name *uint16) (store"...
comment "//sys\tCertOpenStore(storeProvider uintptr, msgAndCertEncodin"...
comment "//sys\tCertEnumCertificatesInStore(store Handle, prevContext "...
comment "//sys\tCertAddCertificateContextToStore(store Handle, certCon"...
comment "//sys\tCertCloseStore(store Handle, flags uint32) (err error)"...
comment "//sys\tCertDeleteCertificateFromStore(certContext *CertContex"...
comment "//sys\tCertDuplicateCertificateContext(certContext *CertConte"...
comment "//sys\tPFXImportCertStore(pfx *CryptDataBlob, password *uint1"...
comment "//sys\tCertGetCertificateChain(engine Handle, leaf *CertConte"...
comment "//sys\tCertFreeCertificateChain(ctx *CertChainContext) = cryp"...
comment "//sys\tCertCreateCertificateContext(certEncodingType uint32, "...
comment "//sys\tCertFreeCertificateContext(ctx *CertContext) (err erro"...
comment "//sys\tCertVerifyCertificateChainPolicy(policyOID uintptr, ch"...
comment "//sys\tCertGetNameString(certContext *CertContext, nameType u"...
comment "//sys\tCertFindExtension(objId *byte, countExtensions uint32,"...
comment "//sys CertFindCertificateInStore(store Handle, certEncodin"...
comment "//sys CertFindChainInStore(store Handle, certEncodingType "...
comment "//sys CryptAcquireCertificatePrivateKey(cert *CertContext,"...
comment "//sys\tCryptQueryObject(objectType uint32, object unsafe.Poin"...
comment "//sys\tCryptDecodeObject(encodingType uint32, structType *byt"...
comment "//sys\tCryptProtectData(dataIn *DataBlob, name *uint16, optio"...
comment "//sys\tCryptUnprotectData(dataIn *DataBlob, name **uint16, op"...
comment "//sys\tWinVerifyTrustEx(hwnd HWND, actionId *GUID, data *WinT"...
comment "//sys\tRegOpenKeyEx(key Handle, subkey *uint16, options uint3"...
comment "//sys\tRegCloseKey(key Handle) (regerrno error) = advapi32.Re"...
comment "//sys\tRegQueryInfoKey(key Handle, class *uint16, classLen *u"...
comment "//sys\tRegEnumKeyEx(key Handle, index uint32, name *uint16, n"...
comment "//sys\tRegQueryValueEx(key Handle, name *uint16, reserved *ui"...
comment "//sys\tRegNotifyChangeKeyValue(key Handle, watchSubtree bool,"...
comment "//sys\tGetCurrentProcessId() (pid uint32) = kernel32.GetCurre"...
comment "//sys\tProcessIdToSessionId(pid uint32, sessionid *uint32) (e"...
comment "//sys\tClosePseudoConsole(console Handle) = kernel32.ClosePse"...
comment "//sys\tcreatePseudoConsole(size uint32, in Handle, out Handle"...
comment "//sys\tGetConsoleMode(console Handle, mode *uint32) (err erro"...
comment "//sys\tSetConsoleMode(console Handle, mode uint32) (err error"...
comment "//sys\tGetConsoleScreenBufferInfo(console Handle, info *Conso"...
comment "//sys\tsetConsoleCursorPosition(console Handle, position uint"...
comment "//sys\tGetConsoleCP() (cp uint32, err error) = kernel32.GetCo"...
comment "//sys\tGetConsoleOutputCP() (cp uint32, err error) = kernel32"...
comment "//sys\tSetConsoleCP(cp uint32) (err error) = kernel32.SetCons"...
comment "//sys\tSetConsoleOutputCP(cp uint32) (err error) = kernel32.S"...
comment "//sys\tWriteConsole(console Handle, buf *uint16, towrite uint"...
comment "//sys\tReadConsole(console Handle, buf *uint16, toread uint32"...
comment "//sys\tresizePseudoConsole(pconsole Handle, size uint32) (hr "...
comment "//sys\tCreateToolhelp32Snapshot(flags uint32, processId uint3"...
comment "//sys\tModule32First(snapshot Handle, moduleEntry *ModuleEntr"...
comment "//sys\tModule32Next(snapshot Handle, moduleEntry *ModuleEntry"...
comment "//sys\tProcess32First(snapshot Handle, procEntry *ProcessEntr"...
comment "//sys\tProcess32Next(snapshot Handle, procEntry *ProcessEntry"...
comment "//sys\tThread32First(snapshot Handle, threadEntry *ThreadEntr"...
comment "//sys\tThread32Next(snapshot Handle, threadEntry *ThreadEntry"...
comment "//sys\tDeviceIoControl(handle Handle, ioControlCode uint32, i"...
comment "// This function returns 1 byte BOOLEAN rather than the 4 by"...
comment "//sys\tCreateSymbolicLink(symlinkfilename *uint16, targetfile"...
comment "//sys\tCreateHardLink(filename *uint16, existingfilename *uin"...
comment "//sys\tGetCurrentThreadId() (id uint32)"
comment "//sys\tCreateEvent(eventAttrs *SecurityAttributes, manualRese"...
comment "//sys\tCreateEventEx(eventAttrs *SecurityAttributes, name *ui"...
comment "//sys\tOpenEvent(desiredAccess uint32, inheritHandle bool, na"...
comment "//sys\tSetEvent(event Handle) (err error) = kernel32.SetEvent"
comment "//sys\tResetEvent(event Handle) (err error) = kernel32.ResetE"...
comment "//sys\tPulseEvent(event Handle) (err error) = kernel32.PulseE"...
comment "//sys\tCreateMutex(mutexAttrs *SecurityAttributes, initialOwn"...
comment "//sys\tCreateMutexEx(mutexAttrs *SecurityAttributes, name *ui"...
comment "//sys\tOpenMutex(desiredAccess uint32, inheritHandle bool, na"...
comment "//sys\tReleaseMutex(mutex Handle) (err error) = kernel32.Rele"...
comment "//sys\tSleepEx(milliseconds uint32, alertable bool) (ret uint"...
comment "//sys\tCreateJobObject(jobAttr *SecurityAttributes, name *uin"...
comment "//sys\tAssignProcessToJobObject(job Handle, process Handle) ("...
comment "//sys\tTerminateJobObject(job Handle, exitCode uint32) (err e"...
comment "//sys\tSetErrorMode(mode uint32) (ret uint32) = kernel32.SetE"...
comment "//sys\tResumeThread(thread Handle) (ret uint32, err error) [f"...
comment "//sys\tSetPriorityClass(process Handle, priorityClass uint32)"...
comment "//sys\tGetPriorityClass(process Handle) (ret uint32, err erro"...
comment "//sys\tQueryInformationJobObject(job Handle, JobObjectInforma"...
comment "//sys\tSetInformationJobObject(job Handle, JobObjectInformati"...
comment "//sys\tGenerateConsoleCtrlEvent(ctrlEvent uint32, processGrou"...
comment "//sys\tGetProcessId(process Handle) (id uint32, err error)"
comment "//sys\tQueryFullProcessImageName(proc Handle, flags uint32, e"...
comment "//sys\tOpenThread(desiredAccess uint32, inheritHandle bool, t"...
comment "//sys\tSetProcessPriorityBoost(process Handle, disable bool) "...
comment "//sys\tGetProcessWorkingSetSizeEx(hProcess Handle, lpMinimumW"...
comment "//sys\tSetProcessWorkingSetSizeEx(hProcess Handle, dwMinimumW"...
comment "//sys\tClearCommBreak(handle Handle) (err error)"
comment "//sys\tClearCommError(handle Handle, lpErrors *uint32, lpStat"...
comment "//sys\tEscapeCommFunction(handle Handle, dwFunc uint32) (err "...
comment "//sys\tGetCommState(handle Handle, lpDCB *DCB) (err error)"
comment "//sys\tGetCommModemStatus(handle Handle, lpModemStat *uint32)"...
comment "//sys\tGetCommTimeouts(handle Handle, timeouts *CommTimeouts)"...
comment "//sys\tPurgeComm(handle Handle, dwFlags uint32) (err error)"
comment "//sys\tSetCommBreak(handle Handle) (err error)"
comment "//sys\tSetCommMask(handle Handle, dwEvtMask uint32) (err erro"...
comment "//sys\tSetCommState(handle Handle, lpDCB *DCB) (err error)"
comment "//sys\tSetCommTimeouts(handle Handle, timeouts *CommTimeouts)"...
comment "//sys\tSetupComm(handle Handle, dwInQueue uint32, dwOutQueue "...
comment "//sys\tWaitCommEvent(handle Handle, lpEvtMask *uint32, lpOver"...
comment "//sys\tGetActiveProcessorCount(groupNumber uint16) (ret uint3"...
comment "//sys\tGetMaximumProcessorCount(groupNumber uint16) (ret uint"...
comment "//sys\tEnumWindows(enumFunc uintptr, param unsafe.Pointer) (e"...
comment "//sys\tEnumChildWindows(hwnd HWND, enumFunc uintptr, param un"...
comment "//sys\tGetClassName(hwnd HWND, className *uint16, maxCount in"...
comment "//sys\tGetDesktopWindow() (hwnd HWND) = user32.GetDesktopWind"...
comment "//sys\tGetForegroundWindow() (hwnd HWND) = user32.GetForegrou"...
comment "//sys\tIsWindow(hwnd HWND) (isWindow bool) = user32.IsWindow"
comment "//sys\tIsWindowUnicode(hwnd HWND) (isUnicode bool) = user32.I"...
comment "//sys\tIsWindowVisible(hwnd HWND) (isVisible bool) = user32.I"...
comment "//sys\tGetGUIThreadInfo(thread uint32, info *GUIThreadInfo) ("...
comment "//sys\tGetLargePageMinimum() (size uintptr)"
comment "// Volume Management Functions"
comment "//sys\tDefineDosDevice(flags uint32, deviceName *uint16, targ"...
comment "//sys\tDeleteVolumeMountPoint(volumeMountPoint *uint16) (err "...
comment "//sys\tFindFirstVolume(volumeName *uint16, bufferLength uint3"...
comment "//sys\tFindFirstVolumeMountPoint(rootPathName *uint16, volume"...
comment "//sys\tFindNextVolume(findVolume Handle, volumeName *uint16, "...
comment "//sys\tFindNextVolumeMountPoint(findVolumeMountPoint Handle, "...
comment "//sys\tFindVolumeClose(findVolume Handle) (err error)"
comment "//sys\tFindVolumeMountPointClose(findVolumeMountPoint Handle)"...
comment "//sys\tGetDiskFreeSpaceEx(directoryName *uint16, freeBytesAva"...
comment "//sys\tGetDriveType(rootPathName *uint16) (driveType uint32) "...
comment "//sys\tGetLogicalDrives() (drivesBitMask uint32, err error) ["...
comment "//sys\tGetLogicalDriveStrings(bufferLength uint32, buffer *ui"...
comment "//sys\tGetVolumeInformation(rootPathName *uint16, volumeNameB"...
comment "//sys\tGetVolumeInformationByHandle(file Handle, volumeNameBu"...
comment "//sys\tGetVolumeNameForVolumeMountPoint(volumeMountPoint *uin"...
comment "//sys\tGetVolumePathName(fileName *uint16, volumePathName *ui"...
comment "//sys\tGetVolumePathNamesForVolumeName(volumeName *uint16, vo"...
comment "//sys\tQueryDosDevice(deviceName *uint16, targetPath *uint16,"...
comment "//sys\tSetVolumeLabel(rootPathName *uint16, volumeName *uint1"...
comment "//sys\tSetVolumeMountPoint(volumeMountPoint *uint16, volumeNa"...
comment "//sys\tInitiateSystemShutdownEx(machineName *uint16, message "...
comment "//sys\tSetProcessShutdownParameters(level uint32, flags uint3"...
comment "//sys\tGetProcessShutdownParameters(level *uint32, flags *uin"...
comment "//sys\tclsidFromString(lpsz *uint16, pclsid *GUID) (ret error"...
comment "//sys\tstringFromGUID2(rguid *GUID, lpsz *uint16, cchMax int3"...
comment "//sys\tcoCreateGuid(pguid *GUID) (ret error) = ole32.CoCreate"...
comment "//sys\tCoTaskMemFree(address unsafe.Pointer) = ole32.CoTaskMe"...
comment "//sys\tCoInitializeEx(reserved uintptr, coInit uint32) (ret e"...
comment "//sys\tCoUninitialize() = ole32.CoUninitialize"
comment "//sys\tCoGetObject(name *uint16, bindOpts *BIND_OPTS3, guid *"...
comment "//sys\tgetProcessPreferredUILanguages(flags uint32, numLangua"...
comment "//sys\tgetThreadPreferredUILanguages(flags uint32, numLanguag"...
comment "//sys\tgetUserPreferredUILanguages(flags uint32, numLanguages"...
comment "//sys\tgetSystemPreferredUILanguages(flags uint32, numLanguag"...
comment "//sys\tfindResource(module Handle, name uintptr, resType uint"...
comment "//sys\tSizeofResource(module Handle, resInfo Handle) (size ui"...
comment "//sys\tLoadResource(module Handle, resInfo Handle) (resData H"...
comment "//sys\tLockResource(resData Handle) (addr uintptr, err error)"...
comment "// Version APIs"
comment "//sys\tGetFileVersionInfoSize(filename string, zeroHandle *Ha"...
comment "//sys\tGetFileVersionInfo(filename string, handle uint32, buf"...
comment "//sys\tVerQueryValue(block unsafe.Pointer, subBlock string, p"...
comment "// Process Status API (PSAPI)"
comment "//sys\tenumProcesses(processIds *uint32, nSize uint32, bytesR"...
comment "//sys\tEnumProcessModules(process Handle, module *Handle, cb "...
comment "//sys\tEnumProcessModulesEx(process Handle, module *Handle, c"...
comment "//sys\tGetModuleInformation(process Handle, module Handle, mo"...
comment "//sys\tGetModuleFileNameEx(process Handle, module Handle, fil"...
comment "//sys\tGetModuleBaseName(process Handle, module Handle, baseN"...
comment "//sys QueryWorkingSetEx(process Handle, pv uintptr, cb uin"...
comment "// NT Native APIs"
comment "//sys\trtlNtStatusToDosErrorNoTeb(ntstatus NTStatus) (ret sys"...
comment "//sys\trtlGetVersion(info *OsVersionInfoEx) (ntstatus error) "...
comment "//sys\trtlGetNtVersionNumbers(majorVersion *uint32, minorVers"...
comment "//sys\tRtlGetCurrentPeb() (peb *PEB) = ntdll.RtlGetCurrentPeb"
comment "//sys\tRtlInitUnicodeString(destinationString *NTUnicodeStrin"...
comment "//sys\tRtlInitString(destinationString *NTString, sourceStrin"...
comment "//sys\tNtCreateFile(handle *Handle, access uint32, oa *OBJECT"...
comment "//sys\tNtCreateNamedPipeFile(pipe *Handle, access uint32, oa "...
comment "//sys\tNtSetInformationFile(handle Handle, iosb *IO_STATUS_BL"...
comment "//sys\tRtlDosPathNameToNtPathName(dosName *uint16, ntName *NT"...
comment "//sys\tRtlDosPathNameToRelativeNtPathName(dosName *uint16, nt"...
comment "//sys\tRtlDefaultNpAcl(acl **ACL) (ntstatus error) = ntdll.Rt"...
comment "//sys\tNtQueryInformationProcess(proc Handle, procInfoClass i"...
comment "//sys\tNtSetInformationProcess(proc Handle, procInfoClass int"...
comment "//sys\tNtQuerySystemInformation(sysInfoClass int32, sysInfo u"...
comment "//sys\tNtSetSystemInformation(sysInfoClass int32, sysInfo uns"...
comment "//sys\tRtlAddFunctionTable(functionTable *RUNTIME_FUNCTION, e"...
comment "//sys\tRtlDeleteFunctionTable(functionTable *RUNTIME_FUNCTION"...
comment "// Desktop Window Manager API (Dwmapi)"
comment "//sys\tDwmGetWindowAttribute(hwnd HWND, attribute uint32, val"...
comment "//sys\tDwmSetWindowAttribute(hwnd HWND, attribute uint32, val"...
comment "// Windows Multimedia API"
comment "//sys TimeBeginPeriod (period uint32) (err error) [failretva"...
comment "//sys TimeEndPeriod (period uint32) (err error) [failretval "...
comment "// syscall interface implementation for other packages"
comment "// GetCurrentProcess returns the handle for the current proc"...
comment "// It is a pseudo handle that does not need to be closed."
comment "// The returned error is always nil."
comment "//"
comment "// Deprecated: use CurrentProcess for the same Handle withou"...
comment "// error."
function_declaration (+28 nodes collapsed)
comment "// CurrentProcess returns the handle for the current process"...
comment "// It is a pseudo handle that does not need to be closed."
function_declaration (+30 nodes collapsed)
comment "// GetCurrentThread returns the handle for the current threa"...
comment "// It is a pseudo handle that does not need to be closed."
comment "// The returned error is always nil."
comment "//"
comment "// Deprecated: use CurrentThread for the same Handle without"...
comment "// error."
function_declaration (+28 nodes collapsed)
comment "// CurrentThread returns the handle for the current thread."
comment "// It is a pseudo handle that does not need to be closed."
function_declaration (+30 nodes collapsed)
comment "// GetProcAddressByOrdinal retrieves the address of the expo"...
comment "// function from module by ordinal."
function_declaration (+99 nodes collapsed)
function_declaration (+25 nodes collapsed)
function_declaration (+55 nodes collapsed)
function_declaration (+403 nodes collapsed)
function_declaration (+98 nodes collapsed)
function_declaration (+105 nodes collapsed)
function_declaration (+120 nodes collapsed)
function_declaration (+123 nodes collapsed)
var_declaration
var "var"
var_spec
identifier "ioSync"
type_identifier "int64"
function_declaration (+194 nodes collapsed)
function_declaration (+28 nodes collapsed)
var_declaration (+35 nodes collapsed)
function_declaration (+36 nodes collapsed)
const_declaration
const "const"
const_spec
identifier "ImplementsGetwd"
= "="
expression_list
true "true"
function_declaration (+110 nodes collapsed)
function_declaration (+55 nodes collapsed)
function_declaration (+61 nodes collapsed)
function_declaration (+55 nodes collapsed)
function_declaration (+55 nodes collapsed)
function_declaration (+88 nodes collapsed)
function_declaration (+111 nodes collapsed)
function_declaration (+36 nodes collapsed)
function_declaration (+97 nodes collapsed)
function_declaration (+59 nodes collapsed)
function_declaration (+114 nodes collapsed)
function_declaration (+185 nodes collapsed)
function_declaration (+181 nodes collapsed)
function_declaration (+28 nodes collapsed)
function_declaration (+118 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+109 nodes collapsed)
comment "// net api calls"
const_declaration
const "const"
const_spec
identifier "socket_error"
= "="
expression_list
call_expression
identifier "uintptr"
argument_list
( "("
unary_expression
^ "^"
call_expression
identifier "uint32"
argument_list
( "("
int_literal "0"
) ")"
) ")"
comment "//sys\tWSAStartup(verreq uint32, data *WSAData) (sockerr erro"...
comment "//sys\tWSACleanup() (err error) [failretval==socket_error] = "...
comment "//sys\tWSAIoctl(s Handle, iocc uint32, inbuf *byte, cbif uint"...
comment "//sys\tWSALookupServiceBegin(querySet *WSAQUERYSET, flags uin"...
comment "//sys\tWSALookupServiceNext(handle Handle, flags uint32, size"...
comment "//sys\tWSALookupServiceEnd(handle Handle) (err error) [failre"...
comment "//sys\tsocket(af int32, typ int32, protocol int32) (handle Ha"...
comment "//sys\tsendto(s Handle, buf []byte, flags int32, to unsafe.Po"...
comment "//sys\trecvfrom(s Handle, buf []byte, flags int32, from *RawS"...
comment "//sys\tSetsockopt(s Handle, level int32, optname int32, optva"...
comment "//sys\tGetsockopt(s Handle, level int32, optname int32, optva"...
comment "//sys\tbind(s Handle, name unsafe.Pointer, namelen int32) (er"...
comment "//sys\tconnect(s Handle, name unsafe.Pointer, namelen int32) "...
comment "//sys\tgetsockname(s Handle, rsa *RawSockaddrAny, addrlen *in"...
comment "//sys\tgetpeername(s Handle, rsa *RawSockaddrAny, addrlen *in"...
comment "//sys\tlisten(s Handle, backlog int32) (err error) [failretva"...
comment "//sys\tshutdown(s Handle, how int32) (err error) [failretval="...
comment "//sys\tClosesocket(s Handle) (err error) [failretval==socket_"...
comment "//sys\tAcceptEx(ls Handle, as Handle, buf *byte, rxdatalen ui"...
comment "//sys\tGetAcceptExSockaddrs(buf *byte, rxdatalen uint32, ladd"...
comment "//sys\tWSARecv(s Handle, bufs *WSABuf, bufcnt uint32, recvd *"...
comment "//sys\tWSASend(s Handle, bufs *WSABuf, bufcnt uint32, sent *u"...
comment "//sys\tWSARecvFrom(s Handle, bufs *WSABuf, bufcnt uint32, rec"...
comment "//sys\tWSASendTo(s Handle, bufs *WSABuf, bufcnt uint32, sent "...
comment "//sys\tWSASocket(af int32, typ int32, protocol int32, protoIn"...
comment "//sys\tWSADuplicateSocket(s Handle, processID uint32, info *W"...
comment "//sys\tGetHostByName(name string) (h *Hostent, err error) [fa"...
comment "//sys\tGetServByName(name string, proto string) (s *Servent, "...
comment "//sys\tNtohs(netshort uint16) (u uint16) = ws2_32.ntohs"
comment "//sys\tGetProtoByName(name string) (p *Protoent, err error) ["...
comment "//sys\tDnsQuery(name string, qtype uint16, options uint32, ex"...
comment "//sys\tDnsRecordListFree(rl *DNSRecord, freetype uint32) = dn"...
comment "//sys\tDnsNameCompare(name1 *uint16, name2 *uint16) (same boo"...
comment "//sys\tGetAddrInfoW(nodename *uint16, servicename *uint16, hi"...
comment "//sys\tFreeAddrInfoW(addrinfo *AddrinfoW) = ws2_32.FreeAddrIn"...
comment "//sys\tGetIfEntry(pIfRow *MibIfRow) (errcode error) = iphlpap"...
comment "//sys\tGetAdaptersInfo(ai *IpAdapterInfo, ol *uint32) (errcod"...
comment "//sys\tSetFileCompletionNotificationModes(handle Handle, flag"...
comment "//sys\tWSAEnumProtocols(protocols *int32, protocolBuffer *WSA"...
comment "//sys\tWSAGetOverlappedResult(h Handle, o *Overlapped, bytes "...
comment "//sys\tGetAdaptersAddresses(family uint32, flags uint32, rese"...
comment "//sys\tGetACP() (acp uint32) = kernel32.GetACP"
comment "//sys\tMultiByteToWideChar(codePage uint32, dwFlags uint32, s"...
comment "//sys\tgetBestInterfaceEx(sockaddr unsafe.Pointer, pdwBestIfI"...
comment "//sys GetIfEntry2Ex(level uint32, row *MibIfRow2) (errcode"...
comment "//sys GetUnicastIpAddressEntry(row *MibUnicastIpAddressRow"...
comment "//sys NotifyIpInterfaceChange(family uint16, callback uint"...
comment "//sys NotifyUnicastIpAddressChange(family uint16, callback"...
comment "//sys CancelMibChangeNotify2(notificationHandle Handle) (e"...
comment "// For testing: clients can set this flag to force"
comment "// creation of IPv6 sockets to return EAFNOSUPPORT."
var_declaration
var "var"
var_spec
identifier "SocketDisableIPv6"
type_identifier "bool"
type_declaration (+30 nodes collapsed)
type_declaration (+29 nodes collapsed)
type_declaration
type "type"
type_spec
type_identifier "RawSockaddr"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Family"
type_identifier "uint16"
field_declaration
field_identifier "Data"
array_type
[ "["
int_literal "14"
] "]"
type_identifier "int8"
} "}"
type_declaration
type "type"
type_spec
type_identifier "RawSockaddrAny"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Addr"
type_identifier "RawSockaddr"
field_declaration
field_identifier "Pad"
array_type
[ "["
int_literal "100"
] "]"
type_identifier "int8"
} "}"
type_declaration (+31 nodes collapsed)
type_declaration (+22 nodes collapsed)
method_declaration (+203 nodes collapsed)
type_declaration (+25 nodes collapsed)
method_declaration (+218 nodes collapsed)
type_declaration
type "type"
type_spec
type_identifier "RawSockaddrUnix"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Family"
type_identifier "uint16"
field_declaration
field_identifier "Path"
array_type
[ "["
identifier "UNIX_PATH_MAX"
] "]"
type_identifier "int8"
} "}"
type_declaration
type "type"
type_spec
type_identifier "SockaddrUnix"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Name"
type_identifier "string"
field_declaration
field_identifier "raw"
type_identifier "RawSockaddrUnix"
} "}"
method_declaration (+308 nodes collapsed)
type_declaration (+37 nodes collapsed)
type_declaration (+21 nodes collapsed)
method_declaration (+225 nodes collapsed)
method_declaration (+484 nodes collapsed)
function_declaration (+77 nodes collapsed)
function_declaration (+100 nodes collapsed)
function_declaration (+67 nodes collapsed)
function_declaration (+67 nodes collapsed)
function_declaration (+67 nodes collapsed)
function_declaration (+90 nodes collapsed)
function_declaration (+90 nodes collapsed)
function_declaration (+39 nodes collapsed)
function_declaration (+39 nodes collapsed)
function_declaration (+152 nodes collapsed)
function_declaration (+22 nodes collapsed)
var_declaration (+21 nodes collapsed)
function_declaration (+196 nodes collapsed)
function_declaration (+199 nodes collapsed)
function_declaration (+137 nodes collapsed)
var_declaration (+24 nodes collapsed)
function_declaration (+315 nodes collapsed)
function_declaration (+188 nodes collapsed)
function_declaration (+179 nodes collapsed)
comment "// Invented structures to support what package os expects."
type_declaration (+21 nodes collapsed)
type_declaration
type "type"
type_spec
type_identifier "WaitStatus"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "ExitCode"
type_identifier "uint32"
} "}"
method_declaration (+21 nodes collapsed)
method_declaration (+29 nodes collapsed)
method_declaration (+23 nodes collapsed)
method_declaration (+21 nodes collapsed)
method_declaration (+21 nodes collapsed)
method_declaration (+21 nodes collapsed)
method_declaration (+23 nodes collapsed)
method_declaration (+21 nodes collapsed)
method_declaration (+23 nodes collapsed)
comment "// Timespec is an invented structure on Windows, but here fo"...
comment "// consistency with the corresponding package for other oper"...
type_declaration
type "type"
type_spec
type_identifier "Timespec"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Sec"
type_identifier "int64"
field_declaration
field_identifier "Nsec"
type_identifier "int64"
} "}"
function_declaration (+40 nodes collapsed)
function_declaration (+45 nodes collapsed)
comment "// TODO(brainman): fix all needed for net"
function_declaration (+38 nodes collapsed)
function_declaration (+132 nodes collapsed)
function_declaration (+87 nodes collapsed)
function_declaration (+38 nodes collapsed)
comment "// The Linger struct is wrong but we only noticed after Go 1"...
comment "// sysLinger is the real system call structure."
comment "// BUG(brainman): The definition of Linger is not appropriat"...
comment "// with Setsockopt and Getsockopt."
comment "// Use SetsockoptLinger instead."
type_declaration
type "type"
type_spec
type_identifier "Linger"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Onoff"
type_identifier "int32"
field_declaration
field_identifier "Linger"
type_identifier "int32"
} "}"
type_declaration
type "type"
type_spec
type_identifier "sysLinger"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Onoff"
type_identifier "uint16"
field_declaration
field_identifier "Linger"
type_identifier "uint16"
} "}"
type_declaration (+25 nodes collapsed)
type_declaration
type "type"
type_spec
type_identifier "IPv6Mreq"
struct_type
struct "struct"
field_declaration_list
{ "{"
field_declaration
field_identifier "Multiaddr"
array_type
[ "["
int_literal "16"
] "]"
type_identifier "byte"
comment "/* in6_addr */"
field_declaration
field_identifier "Interface"
type_identifier "uint32"
} "}"
function_declaration (+119 nodes collapsed)
function_declaration (+130 nodes collapsed)
function_declaration (+84 nodes collapsed)
function_declaration (+91 nodes collapsed)
function_declaration (+38 nodes collapsed)
function_declaration (+91 nodes collapsed)
function_declaration (+29 nodes collapsed)
function_declaration (+84 nodes collapsed)
function_declaration (+68 nodes collapsed)
function_declaration (+184 nodes collapsed)
function_declaration (+61 nodes collapsed)
comment "// TODO(brainman): fix all needed for os"
function_declaration (+26 nodes collapsed)
function_declaration (+28 nodes collapsed)
function_declaration (+28 nodes collapsed)
function_declaration (+30 nodes collapsed)
function_declaration (+34 nodes collapsed)
function_declaration (+34 nodes collapsed)
function_declaration (+34 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+22 nodes collapsed)
function_declaration (+32 nodes collapsed)
type_declaration
type "type"
type_spec
type_identifier "Signal"
type_identifier "int"
method_declaration
func "func"
parameter_list
( "("
parameter_declaration
identifier "s"
type_identifier "Signal"
) ")"
field_identifier "Signal"
parameter_list
( "("
) ")"
block
{ "{"
} "}"
method_declaration (+89 nodes collapsed)
function_declaration (+22 nodes collapsed)
comment "// Readlink returns the destination of the named symbolic li"...
function_declaration (+475 nodes collapsed)
comment "// GUIDFromString parses a string in the form of"
comment "// \"{XXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}\" into a GUID."
function_declaration (+100 nodes collapsed)
comment "// GenerateGUID creates a new random GUID."
function_declaration (+63 nodes collapsed)
comment "// String returns the canonical string form of the GUID,"
comment "// in the form of \"{XXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}\"."
method_declaration (+100 nodes collapsed)
comment "// KnownFolderPath returns a well-known folder path for the "...
comment "// the FOLDERID_ constants, and chosen and optionally create"...
function_declaration (+46 nodes collapsed)
comment "// KnownFolderPath returns a well-known folder path for the "...
comment "// the FOLDERID_ constants, and chosen and optionally create"...
method_declaration (+104 nodes collapsed)
comment "// RtlGetVersion returns the version of the underlying opera"...
comment "// manifest semantics but is affected by the application com"...
function_declaration (+68 nodes collapsed)
comment "// RtlGetNtVersionNumbers returns the version of the underly"...
comment "// ignoring manifest semantics and the application compatibi"...
function_declaration (+45 nodes collapsed)
comment "// GetProcessPreferredUILanguages retrieves the process pref"...
function_declaration (+35 nodes collapsed)
comment "// GetThreadPreferredUILanguages retrieves the thread prefer"...
function_declaration (+35 nodes collapsed)
comment "// GetUserPreferredUILanguages retrieves information about t"...
function_declaration (+35 nodes collapsed)
comment "// GetSystemPreferredUILanguages retrieves the system prefer"...
function_declaration (+35 nodes collapsed)
function_declaration (+330 nodes collapsed)
function_declaration (+54 nodes collapsed)
function_declaration (+27 nodes collapsed)
method_declaration (+29 nodes collapsed)
function_declaration (+36 nodes collapsed)
method_declaration (+180 nodes collapsed)
comment "// NewNTUnicodeString returns a new NTUnicodeString structur"...
comment "// NT APIs that work over the NTUnicodeString type. Note tha"...
comment "// do not use NTUnicodeString, and instead UTF16PtrFromStrin"...
comment "// the more common *uint16 string type."
function_declaration (+114 nodes collapsed)
comment "// Slice returns a uint16 slice that aliases the data in the"...
method_declaration
func "func"
parameter_list
( "("
parameter_declaration
identifier "s"
pointer_type
* "*"
type_identifier "NTUnicodeString"
) ")"
field_identifier "Slice"
parameter_list
( "("
) ")"
slice_type
[ "["
] "]"
type_identifier "uint16"
block
{ "{"
comment "// Note: this rounds the length down, if it happens"
comment "// to (incorrectly) be odd. Probably safer than rounding up."
statement_list
return_statement
return "return"
expression_list
slice_expression
call_expression
selector_expression
identifier "unsafe"
. "."
field_identifier "Slice"
argument_list
( "("
selector_expression
identifier "s"
. "."
field_identifier "Buffer"
, ","
binary_expression
selector_expression
identifier "s"
. "."
field_identifier "MaximumLength"
/ "/"
int_literal "2"
) ")"
[ "["
: ":"
binary_expression
selector_expression
identifier "s"
. "."
field_identifier "Length"
/ "/"
int_literal "2"
] "]"
} "}"
method_declaration (+35 nodes collapsed)
comment "// NewNTString returns a new NTString structure for use with"...
comment "// NT APIs that work over the NTString type. Note that most "...
comment "// do not use NTString, and instead UTF16PtrFromString shoul"...
comment "// the more common *uint16 string type."
function_declaration (+76 nodes collapsed)
comment "// Slice returns a byte slice that aliases the data in the N"...
method_declaration (+56 nodes collapsed)
method_declaration (+35 nodes collapsed)
comment "// FindResource resolves a resource of the given name and re"...
function_declaration (+295 nodes collapsed)
function_declaration (+143 nodes collapsed)
comment "// PSAPI_WORKING_SET_EX_BLOCK contains extended working set "...
type_declaration
type "type"
type_spec
type_identifier "PSAPI_WORKING_SET_EX_BLOCK"
type_identifier "uint64"
comment "// Valid returns the validity of this page."
comment "// If this bit is 1, the subsequent members are valid; other"...
method_declaration (+30 nodes collapsed)
comment "// ShareCount is the number of processes that share this pag"...
method_declaration (+31 nodes collapsed)
comment "// Win32Protection is the memory protection attributes of th"...
comment "// https://docs.microsoft.com/en-us/windows/win32/memory/mem"...
method_declaration (+31 nodes collapsed)
comment "// Shared returns the shared status of this page."
comment "// If this bit is 1, the page can be shared."
method_declaration (+36 nodes collapsed)
comment "// Node is the NUMA node. The maximum value of this member i"...
method_declaration (+31 nodes collapsed)
comment "// Locked returns the locked status of this page."
comment "// If this bit is 1, the virtual page is locked in physical "...
method_declaration (+36 nodes collapsed)
comment "// LargePage returns the large page status of this page."
comment "// If this bit is 1, the page is a large page."
method_declaration (+36 nodes collapsed)
comment "// Bad returns the bad status of this page."
comment "// If this bit is 1, the page is has been reported as bad."
method_declaration (+36 nodes collapsed)
comment "// intField extracts an integer field in the PSAPI_WORKING_S"...
method_declaration (+85 nodes collapsed)
comment "// PSAPI_WORKING_SET_EX_INFORMATION contains extended workin"...
type_declaration
type "type"
type_spec
type_identifier "PSAPI_WORKING_SET_EX_INFORMATION"
struct_type
struct "struct"
field_declaration_list
{ "{"
comment "// The virtual address."
field_declaration
field_identifier "VirtualAddress"
type_identifier "Pointer"
comment "// A PSAPI_WORKING_SET_EX_BLOCK union that indicates the att"...
field_declaration
field_identifier "VirtualAttributes"
type_identifier "PSAPI_WORKING_SET_EX_BLOCK"
} "}"
comment "// CreatePseudoConsole creates a windows pseudo console."
function_declaration (+76 nodes collapsed)
comment "// ResizePseudoConsole resizes the internal buffers of the p"...
function_declaration (+56 nodes collapsed)
comment "// DCB constants. See https://learn.microsoft.com/en-us/wind"...
const_declaration (+149 nodes collapsed)
comment "// EscapeCommFunction constants. See https://learn.microsoft"...
const_declaration (+44 nodes collapsed)
comment "// PurgeComm constants. See https://learn.microsoft.com/en-u"...
const_declaration (+24 nodes collapsed)
comment "// SetCommMask constants. See https://learn.microsoft.com/en"...
const_declaration (+49 nodes collapsed)