Skip to content

[TS] Normalize conditional operands before string concatenation - #392

Merged
CaelmBleidd merged 1 commit into
caelmbleidd/stdlib-source-modelsfrom
caelmbleidd/fix-ts-conditional-string-concat
Sep 22, 2026
Merged

CaelmBleidd merged 1 commit into
caelmbleidd/stdlib-source-modelsfrom
caelmbleidd/fix-ts-conditional-string-concat

Conversation

@CaelmBleidd

Copy link
Copy Markdown
Member

Symbolic string indexing can produce a conditional char | undefined reference. String concatenation queried its type before applying JavaScript coercion, allowing an ITE(ref, null) expression to reach model extraction and fail with Unexpected ref.

Normalize conditional operands branchwise before type lookup and convert concrete nullish values to their JavaScript string representations. Type constraints and witness extraction remain unchanged.

This PR depends on #391.

Validation:

  • ./gradlew :usvm-ts:test :usvm-ts-calls:test --no-daemon
  • CurrentTsCallsSymbolicEngineTest
  • git diff --check

@CaelmBleidd
CaelmBleidd merged commit 8799236 into caelmbleidd/stdlib-source-models Sep 22, 2026
@CaelmBleidd
CaelmBleidd deleted the caelmbleidd/fix-ts-conditional-string-concat branch September 22, 2026 12:28
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