Skip to content

Declare Terminal::read_unicode_character on Windows too - #54

Merged
alexey-milovidov merged 2 commits into
masterfrom
windows-read-unicode-character
Nov 13, 2026
Merged

alexey-milovidov merged 2 commits into
masterfrom
windows-read-unicode-character

Conversation

@alexey-milovidov

Copy link
Copy Markdown
Member

🕵 bracketed_paste calls Terminal::read_unicode_character as a member since #49, but the member was declared and defined only outside _WIN32, so replxx_impl.cxx no longer compiled for Windows. On Windows it now reads one code point from the console with ReadConsoleW, combining a surrogate pair.

Needed by the Windows port in ClickHouse: ClickHouse/ClickHouse#112824

🤖 Generated with Claude Code

`bracketed_paste` calls it as a member of `Terminal` since the merge of
#49, but it was declared and defined
only outside `_WIN32`, so `replxx_impl.cxx` no longer compiled for Windows.
On Windows it reads one code point from the console with `ReadConsoleW`,
combining a surrogate pair.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
alexey-milovidov added a commit to ClickHouse/ClickHouse that referenced this pull request Oct 20, 2026
The updated `replxx` calls `Terminal::read_unicode_character` as a member in
`bracketed_paste`, which was declared only outside `_WIN32`. Point the submodule
at ClickHouse/replxx#54, which declares and defines it on
Windows too, and drop the free function from `replxx-windows-tty.cxx` that it
replaces.

`SocketImpl::acceptConnection` now marks accepted sockets close-on-exec with
`fcntl` where `accept4` is missing; on Windows a socket is a handle, so clear
its `HANDLE_FLAG_INHERIT` instead.

CI report: https://s3.amazonaws.com/clickhouse-test-reports/PRs/112824/6d55c156e6e63e47a0b7cc1cb1a4d06ca54d9c9e/pr/build_amd_windows/build_clickhouse/build_clickhouse.log

Co-Authored-By: Claude Opus 5.5 <[email protected]>

@alexey-milovidov alexey-milovidov left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok.

@alexey-milovidov alexey-milovidov self-assigned this Nov 13, 2026
@alexey-milovidov
alexey-milovidov merged commit 6650850 into master Nov 13, 2026
1 check failed
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