Skip to content

Follow psxlua's fixed a^b and leading-zero numerals - #44

Merged
rixnobis merged 2 commits into
mainfrom
psxlua-pow-strtol
Oct 6, 2026
Merged

rixnobis merged 2 commits into
mainfrom
psxlua-pow-strtol

Conversation

@rixnobis

@rixnobis rixnobis commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

Follows rixnobis/psxlua#9: a^b was a^(b+1) and 010 failed to compile. The host shims now match the fixed code. arith_fold, operators and numbers were recompiled by luac.ps-exe in pcsx-redux; the other 14 expected files did not change. 0x alone is a malformed number now, so it left numbers.lua, and the syntax-error check uses 1.5.

Draft until psxsplash's nugget pin has the fix. Merged before that, exported scripts using ^ on constants would get different bytecode from what psxsplash compiles.

rixnobis/psxlua#9 makes a^b a^b rather than a^(b+1), and parses 010 as
10. The host shims stop reproducing the old behaviour, and "0x" alone
is now a malformed number, as in stock Lua. The three changed expected
files were written by luac.ps-exe at that commit in pcsx-redux; the
other fourteen come out byte-identical to the existing ones.
@rixnobis
rixnobis marked this pull request as ready for review October 6, 2026 07:10
@rixnobis
rixnobis merged commit 25171ff into main Oct 6, 2026
4 checks passed
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