Function clone [src]

Prototype

pub fn clone( func: *const fn (arg: usize) callconv(.c) u8, stack: usize, flags: u32, arg: usize, ptid: ?*i32, tp: usize,ctid: ?*i32, ) usize

Parameters

func: *const fn (arg: usize) callconv(.c) u8stack: usizeflags: u32arg: usizeptid: ?*i32tp: usizectid: ?*i32

Source

pub fn clone( func: *const fn (arg: usize) callconv(.c) u8, stack: usize, flags: u32, arg: usize, ptid: ?*i32, tp: usize, // aka tls ctid: ?*i32, ) usize { // Can't directly call a naked function; cast to C calling convention first. return @as(*const fn ( *const fn (arg: usize) callconv(.c) u8, usize, u32, usize, ?*i32, usize, ?*i32, ) callconv(.c) usize, @ptrCast(&syscall_bits.clone))(func, stack, flags, arg, ptid, tp, ctid); }