Skip to content

Test asm statement separators with CharInSet - #4

Merged
partouf merged 1 commit into
mainfrom
fix/asm-statement-charinset
Oct 8, 2026
Merged

partouf merged 1 commit into
mainfrom
fix/asm-statement-charinset

Conversation

@partouf

@partouf partouf commented Oct 8, 2026

Copy link
Copy Markdown
Member

TPasSyntaxTreeBuilder.AsmStatement decides whether to put a space between the parts of an asm statement with c in [...] on a Char. Since Delphi 2009 Char is a WideChar, so both tests draw W1050 (WideChar reduced to byte char in set expressions).

Every character in the two sets is ASCII, so CharInSet gives the same answer and the warning goes away. FPC's SysUtils has CharInSet as well.

TPasSyntaxTreeBuilder.AsmStatement decides whether to put a space between
the parts of an asm statement with `c in [...]` on a Char. Since Delphi 2009
Char is a WideChar, so both tests draw W1050 (WideChar reduced to byte char
in set expressions).

Every character in the two sets is ASCII, so CharInSet gives the same
answer and the warning goes away. FPC's SysUtils has CharInSet as well.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@partouf
partouf merged commit 9d93519 into main Oct 8, 2026
2 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