Skip to content

fix(stdlib): preserve string types in prefixes and suffixes 馃У - #218

Merged
timfennis merged 1 commit into
masterfrom
fix/string-prefixes-suffixes-types
Sep 8, 2026
Merged

fix(stdlib): preserve string types in prefixes and suffixes 馃У#218
timfennis merged 1 commit into
masterfrom
fix/string-prefixes-suffixes-types

Conversation

@timfennis

Copy link
Copy Markdown
Owner

You get List<Any> from string prefixes and suffixes calls, which prevents assignments to List<String>. Add String overloads with List<String> return types and share the string implementations with the sequence fallback.

I added regression tests for inferred return types, Unicode and empty strings, and calls through sequence annotations and untyped parameters. I ran cargo fmt --all and cargo test --workspace; the workspace suite passed.

AI disclosure: OpenAI Codex generated the implementation, tests, and PR prose.

@timfennis
timfennis merged commit 2ed1d1b into master Sep 8, 2026
1 check passed
@timfennis
timfennis deleted the fix/string-prefixes-suffixes-types branch September 8, 2026 10:46
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