DMARC-Filter: OpenDMARC Filter v1.4.2 delorie.com 581HiutJ2947949 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 581HiutJ2947949 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=DMyCGbhw X-Recipient: archive-cygwin AT delorie DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1F5643858C62 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; s=default; t=1756748694; bh=AjlGQlYEVZu1DfLsw784s5+hyx4Bukkt42lF5xUn0Rw=; h=Date:Subject:To:References:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=DMyCGbhwQtWnmtRA9N0rlCw28zEi+qY24zVKxfFJL+GG+AXmyaScJ8MbDJFvppO1B +WP8wzRPHbHTblWfq3bmBA4JJK2p1Ysm2wiptttpW88nYSXi46znxia5Q5TZwHHg9Y gjMaQJ9bvtppwHFr3r65EiE4hGSMA6UHXWkPDFPs= X-Original-To: cygwin AT cygwin DOT com Delivered-To: cygwin AT cygwin DOT com DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 161093858C62 ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 161093858C62 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1756747166; cv=none; b=aTU491SM4abgQ9AcSELSodKWyw5RthnVshL/TE4CJ2IKwiDdKczW2O/BLNhsEnVP8mHWZkodAaEMwJIRd/qt3/IX63//LuiXw10Xt9fTwJkM1gpMafMEcHFkeS+/mA/QjdxO3OLw9iYVP3MqsWu7pe39+enKOcQ4b/eeHw8kwwU= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1756747166; c=relaxed/simple; bh=j1nBfOVITVvcHSEKE9QNIEfU8IS6/FBMyUPnYHe8kuc=; h=Message-ID:Date:MIME-Version:From:Subject:To:DKIM-Signature; b=eOudK8ANfXF6EHxqGmu3r3UFArSWFPym3MPGEWW6TYOtLAqhzBDYQdtls1PnEmOAG1UqGsjs+5OVjxAyQ2gMmvY0AAObgKXKtioOS97kLDt+z3Lw+4g0SRHzyifvjzb8WyUe6scSUMDY4shPplym/0NsBCUcTqjsR5bQAGqNNFw= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 161093858C62 Message-ID: <50ef4d1a-fab5-4711-b17a-5d26e74c4881@SystematicSW.ab.ca> Date: Mon, 1 Sep 2025 11:19:18 -0600 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bash 5.2.21-1: a bug in [0-9] expansion Content-Language: en-CA To: cygwin AT cygwin DOT com References: Organization: Systematic Software In-Reply-To: X-Stat-Signature: tmm7o4gazf1jrfqyxtyj666ig59mfhmb X-Rspamd-Server: rspamout03 X-Rspamd-Queue-Id: 468B220024 X-Session-Marker: 427269616E2E496E676C69734053797374656D6174696353572E61622E6361 X-Session-ID: U2FsdGVkX191d+ODdJvwaGT6ViHLiwLz9DkkuRgCII4= X-HE-Tag: 1756747159-157213 X-HE-Meta: U2FsdGVkX19JUpBj63UA9FdZcpJKEiSfhkl1h2W/FyfnjwAsV5Y3MsL1zRQBhc4ihOPKtWI/s/s3CuPrmfoKzWsPprRxFi1ARREoh0OKo8UYmXiPsMIYGvnt5WFvJxUhMa3TaQ8wWPYZiKhA8rML6CfVbDrvWEe3y6U4N1eWvxh2dxGvIlMP151oAvitFsooinAVwjxO6uWTvtbQl4W7boWcFZMemHZcPmOF9g6nt6uybzB1kg9ShPAWAMEgcT1F2MZ1zwCFn3noXMLhTqQX2dVvwfcqjcpEWSyxlnVQJbjCzABInGut9glNLswKPojisnNf4tCbloTXdK3XZmTqI42nz96ybdwwEdGFECLRV2mNulMlhy0ayQ== X-BeenThere: cygwin AT cygwin DOT com X-Mailman-Version: 2.1.30 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Brian Inglis via Cygwin Reply-To: cygwin AT cygwin DOT com Cc: Brian Inglis Content-Type: text/plain; charset="utf-8"; Format="flowed" Errors-To: cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com Sender: "Cygwin" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by delorie.com id 581HiutJ2947949 On 2025-08-31 13:06, Mariusz Wodzicki via Cygwin wrote: > Description of the problem. > [0-9] picks also certain Unicode superscript characters ( namely, ⁰ ⁴ ⁵ ⁶ > ⁷ ⁸ ⁹ ), and every Unicode subscript character. > > Example: the directory has the following files: > $ /bin/ls > ₀.txt ₁.txt ₂.txt ₃.txt ₄.txt ₅.txt ₆.txt ₇.txt ₈.txt ₉.txt > ⁰.txt ¹.txt ².txt ³.txt ⁴.txt ⁵.txt ⁶.txt ⁷.txt ⁸.txt ⁹.txt > > $ /bin/ls [0-9].txt > ₀.txt ₁.txt ₃.txt ⁴.txt ⁵.txt ⁶.txt ⁷.txt ⁸.txt > ⁰.txt ₂.txt ₄.txt ₅.txt ₆.txt ₇.txt ₈.txt > > $ locale > LANG=en_US.UTF-8 > LC_CTYPE="en_US.UTF-8" > LC_NUMERIC="en_US.UTF-8" > LC_TIME="en_US.UTF-8" > LC_COLLATE="en_US.UTF-8" > LC_MONETARY="en_US.UTF-8" > LC_MESSAGES="en_US.UTF-8" > LC_ALL= > > System. > Fully up to date Windows 11 > cygwin 3.6.4-1 > bash 5.2.21-1 For reproducible results prefix commands with LC_ALL=C … or possibly just LC_COLLATE=C or LC_CTYPE=C or =POSIX to standardize the locale, otherwise many commands will respect the current locale, and some respect Unicode regardless of locale e.g. `info wc`: "Unless the environment variable ‘POSIXLY_CORRECT’ is set, GNU ‘wc’ treats the following Unicode characters as white space even if the current locale does not: U+00A0 NO-BREAK SPACE, U+2007 FIGURE SPACE, U+202F NARROW NO-BREAK SPACE, and U+2060 WORD JOINER." For GNU utilities, where info pages are preferred, such as coreutils*, compiler and language processors, and tools packages, many details do not appear in the man pages, for example: "Full documentation or available locally via: info '(coreutils) wc invocation'" although `info wc` shows the same page. ————— * [ arch b2sum base32 base64 basename cat chcon chgrp chmod chown chroot cksum comm cp csplit cut date dd df dir dircolors dirname du echo env expand expr factor false fmt fold gkill groups head hostid id install join link ln logname ls md5sum mkdir mkfifo mknod mktemp mv nice nl nohup nproc numfmt od paste pathchk pinky pr printenv printf ptx pwd readlink realpath rm rmdir runcon seq sha1sum sha224sum sha256sum sha384sum sha512sum shred shuf sleep sort split stat stdbuf stty sum sync tac tail tee test timeout touch tr true truncate tsort tty uname unexpand uniq unlink users vdir wc who whoami yes -- Take care. Thanks, Brian Inglis Calgary, Alberta, Canada La perfection est atteinte Perfection is achieved non pas lorsqu'il n'y a plus rien à ajouter not when there is no more to add mais lorsqu'il n'y a plus rien à retrancher but when there is no more to cut -- Antoine de Saint-Exupéry -- 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