← All docs

pcntl_setns() — internals

Compiler internals for pcntl_setns(): lowering path, type checks, and runtime helpers.

pcntl_setns() — internals

Where it lives

Lowering notes

  • Uses the runtime_call strategy from the single-source builtin descriptor.
  • Emits the typed EIR target runtime.pcntl.setns through BuiltinLoweringContext.
  • The backend resolves that typed target through src/codegen/lower_inst/runtime_calls.rs; PHP builtin names do not participate in dispatch.

Semantic descriptor

  • Target strategy: runtime_call
  • Validation: shared
  • Result type source: declared
  • Result ownership: non_heap
  • Effects: static (6 declared effects)
  • Requirements: static (1 requirements)
  • Callable policy: static_only
  • Target support: linux-aarch64, linux-x86_64

EIR and runtime boundary

  • Typed EIR target: runtime.pcntl.setns
  • Backend boundary: src/codegen/lower_inst/runtime_calls.rs resolves the typed target without PHP-name dispatch.

Signature summary

function pcntl_setns(int $process_id = null, int $nstype = 1073741824): bool

What the type checker enforces

  • Arity: takes 0–2 arguments (2 optional).

Eval interpreter (magician)

Cross-references