| www.delorie.com/archives/browse.cgi | search |
| DMARC-Filter: | OpenDMARC Filter v1.4.2 delorie.com 651K5TRb3824932 |
| Authentication-Results: | delorie.com; dmarc=pass (p=none dis=none) header.from=cygwin.com |
| Authentication-Results: | delorie.com; spf=pass smtp.mailfrom=cygwin.com |
| DKIM-Filter: | OpenDKIM Filter v2.11.0 delorie.com 651K5TRb3824932 |
| Authentication-Results: | delorie.com; |
| dkim=pass (1024-bit key, unprotected) header.d=cygwin.com header.i=@cygwin.com header.a=rsa-sha256 header.s=default header.b=rqF+dFl5 | |
| X-Recipient: | archive-cygwin AT delorie DOT com |
| DKIM-Filter: | OpenDKIM Filter v2.11.0 sourceware.org 7146B4BA2E2B |
| DKIM-Signature: | v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; |
| s=default; t=1780344328; | |
| bh=a0Y9t07bCrnIgvfMrSSxgy0Niw58fN8EZNkBZJQwswU=; | |
| h=To:Subject:In-Reply-To:References:Date:List-Id:List-Unsubscribe: | |
| List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: | |
| From; | |
| b=rqF+dFl5+iGiG02tvB/SAs0xYtybNsRGs9CQba4VdnWNwFt8mR5CMsaK+PsxnSx8i | |
| ukmMpi5iCsix1FBBQu9WldBAoHxne8lF8P4QWwFMnuY55QREoQQZIEKQ2OOS+8J0AN | |
| kYCTGCtvui6l6JozVfk45u3nn9mH6haWDINn2Vgo= | |
| X-Original-To: | cygwin AT cygwin DOT com |
| Delivered-To: | cygwin AT cygwin DOT com |
| DMARC-Filter: | OpenDMARC Filter v1.4.2 sourceware.org 609004BA2E09 |
| ARC-Filter: | OpenARC Filter v1.0.0 sourceware.org 609004BA2E09 |
| ARC-Seal: | i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1780344277; cv=none; |
| b=IfTa/h3XruoovfK7B3YeGb6TQiTkSLLjARbriH7WvuDdcopvJhGnKCYJ6otIHgbYGFuQwfOCpvAYwa7zjE2pNNfYLncefL34bA3zJWmNZrUimHIu/s5ZJVz2J8qSliP2rVu+AzItBZkBY9MnGwYLS2NVEm00CHADoMrB2VNv5M8= | |
| ARC-Message-Signature: | i=1; a=rsa-sha256; d=sourceware.org; s=key; |
| t=1780344277; c=relaxed/simple; | |
| bh=cA1Y75/z6wA7chnemx/b8f0iIh5GtGSXF50RUzAskC8=; | |
| h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; | |
| b=RnDUT2VYwWa5lprO8A/Iv4dgaMce4htKzie9JfvdU3UPsSQs/EDBkhNgtOmdSs/g82S1GD9AsIrKUb77IPECZedn6g0jwHAwZuDUZ41m+bdh8QnVmkUiCcvWEMOsoIYVEauTuoiUNnBkHB9lYFnqUAYMhi2QJKGeoG6y9tG8PAc= | |
| ARC-Authentication-Results: | i=1; sourceware.org; |
| dkim=pass (1024-bit key, secure) header.d=nexgo.de | |
| header.i=@nexgo.de header.a=rsa-sha256 header.s=vfde-mb-mr2-23sep | |
| header.b=ep87roJN | |
| DKIM-Filter: | OpenDKIM Filter v2.11.0 sourceware.org 609004BA2E09 |
| To: | cygwin AT cygwin DOT com |
| Subject: | Re: wcwidth broken with gcc 16 |
| In-Reply-To: | <5c46f199-128c-4409-a354-9d3e1deb29bb@towo.net> (Thomas Wolff via |
| Cygwin's message of "Mon, 1 Jun 2026 10:13:01 +0200") | |
| References: | <a9676834-0368-4a8a-88b0-da5e9483b536 AT towo DOT net> |
| <874ikpawdk DOT fsf AT Gerda DOT invalid> | |
| <8ff2ab8d-dfdc-459c-96f3-ed4a4f451440 AT towo DOT net> | |
| <0140C1F4-CA22-46DE-AE21-69C5427C59B5 AT unified-streaming DOT com> | |
| <e94174b7-ea9b-45ca-bfd3-7979ce988920 AT towo DOT net> | |
| <e362b49c-521c-4cd5-8963-c17d5770619b AT SystematicSW DOT ab DOT ca> | |
| <fbbeb91a-4c5a-dbe6-1bb3-206cf14a73bc AT wisemo DOT com> | |
| <4f885156-7772-43d7-ab72-c88f0a7d1e52 AT towo DOT net> | |
| <112594ad-3c25-4dad-b1bc-071b4951ed98 AT towo DOT net> | |
| <97f0f3c6-9f2c-429c-aa8e-875b7806b275 AT towo DOT net> | |
| <8733z9jpfj DOT fsf AT Gerda DOT invalid> | |
| <b70d8366-8970-4cdc-a693-6d826fe76277 AT towo DOT net> | |
| <b8c1571a-1956-4316-a6a9-32176b6c7c80 AT towo DOT net> | |
| <87pl2bab08 DOT fsf AT Gerda DOT invalid> | |
| <2a39e204-bd8b-4511-bd34-703899600e9e AT towo DOT net> | |
| <87ldcza133 DOT fsf AT Gerda DOT invalid> | |
| <21ca1d38-7b82-49af-b954-b83141237843 AT towo DOT net> | |
| <5c46f199-128c-4409-a354-9d3e1deb29bb AT towo DOT net> | |
| Date: | Mon, 01 Jun 2026 22:04:21 +0200 |
| Message-ID: | <87y0gyyqm2.fsf@Gerda.invalid> |
| User-Agent: | Gnus/5.13 (Gnus v5.13) |
| MIME-Version: | 1.0 |
| X-purgate-server: | smtpa05 |
| X-purgate-type: | clean |
| X-purgate: | clean |
| X-purgate-size: | 2274 |
| X-purgate-ID: | 155817::1780344270-9FCD2F46-325BB408/0/0 |
| X-BeenThere: | cygwin AT cygwin DOT com |
| X-Mailman-Version: | 2.1.30 |
| List-Id: | General Cygwin discussions and problem reports <cygwin.cygwin.com> |
| List-Unsubscribe: | <https://cygwin.com/mailman/options/cygwin>, |
| <mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe> | |
| List-Archive: | <https://cygwin.com/pipermail/cygwin/> |
| List-Post: | <mailto:cygwin AT cygwin DOT com> |
| List-Help: | <mailto:cygwin-request AT cygwin DOT com?subject=help> |
| List-Subscribe: | <https://cygwin.com/mailman/listinfo/cygwin>, |
| <mailto:cygwin-request AT cygwin DOT com?subject=subscribe> | |
| From: | ASSI via Cygwin <cygwin AT cygwin DOT com> |
| Reply-To: | ASSI <Stromeko AT nexgo DOT de> |
| Errors-To: | cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com |
| Sender: | "Cygwin" <cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com> |
Thomas Wolff via Cygwin writes: >> Which part of "you must not change a standard public API" is unclear to you? > Who defines that? Reference? After all, it would be a compatible > extension, not the most unusal thing to do. It makes a difference on Cygwin because wchar_t and wint_t are not the same width (and wchar_t is not supposed to be signed anyway even if they were). >> Especially when it would make things binary incompatible? > I don't see any incompatibilites that might arise on cygwin. Exactly the same one that had you open a bug for gcc: a compiler that uses wchar_t for the argument does not need to care about any upper bits left in the register that will go into the function and the function call (taking a win_t) does. Whether there actually are any binaries that have this problem is left as an exercise for the reader, but the mere possibility for one to exist makes this a no-go. >> WCHAR_MAX is 0xffffu on Cygwin, so the above is illegal input to wcwidth and it never worked. > Well, my proposal was just to make it work. But you may well argue it > doesn't need to. Again, there is no existing code that can produce such a result (given how wchar_t is currently defined and was from the very beginning), so there is nothing to fix. And you can't change it without invalidating existing binaries. > If you patch wcwidth.c as you suggest, make sure however *not* to > bit-reduce __wcwidth because that would break wcswidth which must > continue to work for non-BMP characters passed as surrogate pairs. Nobody ever suggested that. IIRC the internal function __wcwidth that is called through the stub implementation has always been taking a wint_t. I don't know if there's a precedent for an additional API function (most certainly not POSIX) that exists on systems that have the same characteristics as Windows (and Cygwin) of wchar_t not quite large enough to fit all codepoints in order to enable that functionality via either a wint_t or some additional unsigned wchar-like type. Regards, Achim. -- +<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+ Factory and User Sound Singles for Waldorf Q+, Q and microQ: http://Synth.Stromeko.net/Downloads.html#WaldorfSounds -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |