mirror of
https://github.com/denoland/deno.git
synced 2024-11-21 20:38:55 +00:00
fix(runtime): return number from op_ppid
instead of bigint (#22169)
Fixes #22166
This commit is contained in:
parent
345423cf76
commit
ab8b1b11d7
@ -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 New Issue
Block a user