aboutsummaryrefslogtreecommitdiff
path: root/test/bun.js/ffi.test.js (follow)
AgeCommit message (Collapse)AuthorFilesLines
2022-11-09Add bun-types, add typechecking, add `child_process` types (#1475)Gravatar Colin McDonnell 1-18/+18
* Add bun-types to packages * Improve typing * Fix types in tests * Fix dts tests * Run formatter * Fix all type errors * Add strict mode, fix type errors * Add ffi changes * Move workflows to root * Add workflows * Remove labeler * Add child_process types * Fix synthetic defaults issue * Remove docs * Move scripts * Run prettier * Include examples in typechecking * captureStackTrace types * moved captureStackTrace types to globals * Address reviews Co-authored-by: Colin McDonnell <colinmcd@alum.mit.edu> Co-authored-by: Dylan Conway <dylan.conway567@gmail.com>
2022-11-02[bun:ffi] Add `threadsafe` option to callbacksGravatar Jarred Sumner 1-11/+26
2022-11-02[bun:ffi] Implement `JSCallback` so C can call into JSGravatar Jarred Sumner 1-97/+67
2022-09-09[bun:ffi] Add `f32`, `f64`, `i64`, u64` to `read`Gravatar Jarred Sumner 1-2/+11
2022-09-08Last commit was missing some codeGravatar Jarred Sumner 1-23/+22
2022-09-08[bun:ffi] Implement `read.{u8,i8,i16,i32,u16,u32,ptr,intptr}`Gravatar Jarred Sumner 1-0/+23
`read` in `bun:ffi` lets you read data from a pointer without creating a new DataView/ArrayBufferView ``` import {read} from 'bun:ffi'; expect(read.i8(ptr_, i)).toBe(view.getInt8(i, true)); expect(read.i16(ptr_, i)).toBe(view.getInt16(i, true)); expect(read.i32(ptr_, i)).toBe(view.getInt32(i, true)); expect(read.u8(ptr_, i)).toBe(view.getUint8(i, true)); expect(read.u16(ptr_, i)).toBe(view.getUint16(i, true)); expect(read.u32(ptr_, i)).toBe(view.getUint32(i, true)); } ```
2022-09-06workaround test failureGravatar Jarred Sumner 1-31/+33
2022-08-28support pass null as NULL ptr (#1160)Gravatar Zilin Zhu 1-0/+7
2022-08-27Fix ffi uint64_t parameter (#1158)Gravatar Zilin Zhu 1-30/+56
2022-08-12Update WebKitGravatar Jarred Sumner 1-13/+14
2022-08-10Fix console.log with typed arraysGravatar Jarred Sumner 1-16/+16
2022-08-09[bun:ffi] Re-enable most of the testsGravatar Jarred Sumner 1-543/+582
2022-06-22change the directory structurejarred/renameGravatar Jarred Sumner 1-0/+543