Skip to content

Commit

Permalink
Merge pull request #202 from swsnr/197-improve-system-module-types
Browse files Browse the repository at this point in the history
Improve System module types
  • Loading branch information
JumpLink committed Sep 20, 2024
2 parents 37b4245 + cec27b0 commit 8480ec5
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions packages/generator-typescript/templates/gjs/system.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export const programArgs: string[]
* @param o Any Object
* @returns A hexadecimal string (e.g. `0xb4f170f0`)
*/
export function addressOf(o: any): string
export function addressOf(o: object): string

/**
* Return the memory address of any GObject as a string.
Expand Down Expand Up @@ -141,26 +141,26 @@ export function dumpHeap(path?: string): void
* }
* }
* ```
*
*
*/
export function dumpMemoryInfo(path?: string): void

/**
* This works the same as C's exit() function; exits the program, passing a
* certain error code to the shell. The shell expects the error code to be zero if
* there was no error, or non-zero (any value you please) to indicate an error.
*
*
* This value is used by other tools such as `make`; if `make` calls a program that
* returns a non-zero error code, then `make` aborts the build.
* @param code An exit code
*/
export function exit(code: number): void
export function exit(code: number): never

/**
* The System module provides common low-level facilities such as access to
* process arguments and exit(), as well as a number of useful functions and
* properties for debugging.
*
*
* Note that the majority of the functions and properties in this module should not
* be used in normal operation of a GJS application.
*/
Expand All @@ -184,4 +184,4 @@ export default System

<%_ if(!package){ -%>
}
<% } -%>
<% } -%>

0 comments on commit 8480ec5

Please sign in to comment.