mirror of
https://github.com/denoland/deno.git
synced 2024-12-23 07:44:48 -05:00
fix(runtime): return number from op_ppid
instead of bigint (#22169)
Fixes #22166
This commit is contained in:
parent
345423cf76
commit
ab8b1b11d7
2 changed files with 3 additions and 1 deletions
|
@ -158,10 +158,12 @@ Deno.test({ permissions: { env: true } }, function envInvalidChars() {
|
|||
});
|
||||
|
||||
Deno.test(function osPid() {
|
||||
assertEquals(typeof Deno.pid, "number");
|
||||
assert(Deno.pid > 0);
|
||||
});
|
||||
|
||||
Deno.test(function osPpid() {
|
||||
assertEquals(typeof Deno.ppid, "number");
|
||||
assert(Deno.ppid > 0);
|
||||
});
|
||||
|
||||
|
|
|
@ -32,7 +32,7 @@ fn op_main_module(state: &mut OpState) -> Result<String, AnyError> {
|
|||
/// This is an op instead of being done at initialization time because
|
||||
/// it's expensive to retrieve the ppid on Windows.
|
||||
#[op2(fast)]
|
||||
#[bigint]
|
||||
#[number]
|
||||
pub fn op_ppid() -> i64 {
|
||||
#[cfg(windows)]
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue