~/talk

Calling Functions Across Languages

slides:none on file

Shows how to replace network or process RPC with direct in-process calls using C FFIs so Node.js can call Ruby (and Python, Fortran, etc.), converting JS/Ruby shapes via N-API and Ruby C API to avoid misinterpreted bit patterns. Benchmarks note pipes under 8K are fastest, shared memory wins for larger payloads. Demonstrates a working C shim that converts arrays, explains crash risks (segfaults from layout mismatches) and presents Rock glue as a generator to auto-produce safe bindings instead of hand-writing C.

AI-written summary · about

  1. 0:00Introduction to cross-language calls
  2. 2:26HTTP call from JavaScript to Ruby
  3. 11:13Moving to single-process calls
  4. 23:25Using C as an intermediary
  5. 31:08Making cross-language calls less painful
  6. 37:23Generating bindings automatically
  7. 44:19Trade-offs of different approaches
  8. 48:10Summary and closing
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.