Skip to content

Stdlib: sin/cos/tan and compiler test fixes - #11

Merged
PurHur merged 1 commit into
masterfrom
stdlib-trig-sin-cos-tan
May 17, 2026
Merged

Stdlib: sin/cos/tan and compiler test fixes#11
PurHur merged 1 commit into
masterfrom
stdlib-trig-sin-cos-tan

Conversation

@PurHur

@PurHur PurHur commented May 17, 2026

Copy link
Copy Markdown
Owner

Summary

  • Add sin(), cos(), and tan() to the standard extension with compliance and integration PHPT specs.
  • Rewrite decbin() as a native Internal implementation (fixes runtime failure from compiled-PHP namespaced calls).
  • Support INF and NAN constants in the VM and implement VM::raise() for clearer constant-fetch errors.
  • Improve local/CI test execution: load required PHP extensions in subprocess tests, set repo cwd for proc_open, and fix RealWorldTest missing setUp().

Test plan

  • PHP_COMPILER_EXT_DIR=/usr/lib/php/20220829 php vendor/bin/phpunit (167 tests, 76 JIT skipped without LLVM)
  • VM compliance and real-world stdlib specs pass

Made with Cursor

Add trigonometric builtins with PHPT specs, rewrite decbin as a native
Internal function, support INF/NAN constants in the VM, and fix compliance
test execution (extension loading, cwd, RealWorldTest setUp).

Co-authored-by: Cursor <cursoragent@cursor.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant