From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_EF,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham autolearn_force=no version=3.4.4 Received: from zero.zsh.org (zero.zsh.org [IPv6:2a02:898:31:0:48:4558:7a:7368]) by inbox.vuxu.org (Postfix) with ESMTP id E176E26060 for ; Mon, 6 May 2024 05:23:38 +0200 (CEST) ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1714965818; b=IVN+xqvTJ+BKCuS0tSrocpM+VQ5yONO+y9sy5XizIqNOH1gRFqBXoaVgzvvQcSLySPTnIMfT0w k0RWyeM4ToVgVO5uRM8PCx6S9EsRfjGLPd1J4BKcvhmQqmV0ZKIiChYYuvxudm2nL/zdmS7Ode BMjwRjY6+SpaCL6RRXGxGfos/fUo8kjgvCfQLT33aPNtTo0n3gqsECD/gMUXOp28Pn+iIw+XMu OdTX7oPHAZ0vi6kLOMtwfLFAXs5fNhXOuTVCFLmd9YHp2K7aRGkW2vZcgXtSeRAUmCt9D3L6QV fdvmBXYA/KzXJb3yU1zk1sW/+Nc43/TjCx+A8FTAZ68E7Q==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-lf1-f44.google.com) smtp.remote-ip=209.85.167.44; dkim=pass header.d=brasslantern-com.20230601.gappssmtp.com header.s=20230601 header.a=rsa-sha256; dmarc=none header.from=brasslantern.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1714965818; bh=943AhBGUItVX3asmptQXbFaeYEX90PYUpZf5ujQZ5+U=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Transfer-Encoding:Content-Type:Cc:To:Subject: Message-ID:Date:From:In-Reply-To:References:MIME-Version:DKIM-Signature: DKIM-Signature; b=OWM3mesAVuzrq3o4WUz6jhbUgcnFqflirC1KDIMrpaYHuqJBUiJiyuwuKfrI3RYNifFu+H7HgV qYCOhteVritufvZXvvA0bXg3rmSbxCtVWq/Nd1GoO7ge50kBF3FjUK2hPn+KbAc1bcGh7eR071 +n3Tt+wc/ztsq/RqKAtLWbhsp2Rhgf/xNiKbfZmhEmWQ4jTeVu04/BmzLbsQ9fzkStoqfrICiO S4/399+fD4AmuKoFRYvTmZJfRvw3WlpqEwdHlYO90tLH3JiBkFMNaaRFKhBRYQSXBF65fZWgtA UF6kIogi3HAM0nBbhwrr6eBvJ6Q/VMJuExoYX8OKVNGBVw==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20210803; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Transfer-Encoding: Content-Type:Cc:To:Subject:Message-ID:Date:From:In-Reply-To:References: MIME-Version:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=zLE+NshtiPYqhDsMw5ihb7kh3nTHTnAzkD3ifm1iS7k=; b=o09iqPqKFDZ9dFPqpQHLM0jHRi aTu3b5MZ6Wpe/VnORDw9cXU1cepHuw+xWJnWAPlfT3zNCcbDU/b1yM3cs3a+BlaqPgOwIkifAZw94 r9l9biFT46uvdRY9Ertv58p2W7EUz2fjdnsdThxxXc6S2ca0ovELDEKzlLe0BbvTsh9cCx2vTZK19 G/1t0J/YOrdllAImESSRxA2nMmU9lx5t97jVcopInwTa55YG/jOJjxuLnZQt+FOCMRZZd6FWAQpHJ 4iLajrhx1+U0havEW6MTCrHqJlff4rlKJJQC5vuCy6zWIS4w21pilOo2TJPHOcPB8hByqWXdaLMD2 LgcwCevg==; Received: by zero.zsh.org with local id 1s3owz-000381-84; Mon, 06 May 2024 03:23:37 +0000 Authentication-Results: zsh.org; iprev=pass (mail-lf1-f44.google.com) smtp.remote-ip=209.85.167.44; dkim=pass header.d=brasslantern-com.20230601.gappssmtp.com header.s=20230601 header.a=rsa-sha256; dmarc=none header.from=brasslantern.com; arc=none Received: from mail-lf1-f44.google.com ([209.85.167.44]:56514) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1s3ow7-0002Ss-O2; Mon, 06 May 2024 03:22:44 +0000 Received: by mail-lf1-f44.google.com with SMTP id 2adb3069b0e04-51fc01b6fe7so1130193e87.0 for ; Sun, 05 May 2024 20:22:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brasslantern-com.20230601.gappssmtp.com; s=20230601; t=1714965762; x=1715570562; darn=zsh.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=zLE+NshtiPYqhDsMw5ihb7kh3nTHTnAzkD3ifm1iS7k=; b=U76oybXP5d6zNrwbFymNL8bSvHaBPKBGYBbo8PwZtPGTkm/xt2y2B0wEO1cmDc8tnp qLONyFh4x0K8hq5TyqdyZJM5TdeEZkWOOXvOqrfIs8FCoIrYij8rThPZ+AFsi5uCc1tc 0tDf4PHHlPTXhkqgJuUNm7w6jYwL3GsmSb6df2pzgabcKLRi0wnvF0Hsju+XBriSNcZx 4GUs5wh8uaEm4rLKFpha0vzuCfcYx2lTDA14JobeXuNO9kY+lckMZI8GbznfXdkEKGNN 1iHX0dJCbXtSrr2YOxYVkOmXHZVg1GKzWHovxXE1HHVbU49mMOlc111+Ekn01znN/g4z eHow== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1714965762; x=1715570562; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=zLE+NshtiPYqhDsMw5ihb7kh3nTHTnAzkD3ifm1iS7k=; b=uybNXE/TFodIytEl3LlAf7ldY87xePUwDyT7fUVsBLsvWUngxHYq4PakGz9gSzuU+S Qkx0HHgXM+ktd29oO/10eZTrFKbRdk6KpE14NUUAiKljKDTyrssk+9Wh+j9RG2i+4HIP 2tVO2RUbsur49D6d5sqkDpWq0ZXakuRSoSRy3oMGPmjeJ6VGdPn5Ac8NaR+tzl2OgrQJ c0idjtKrOh//B7sQCFjFSrhLKJULAFBtSh74+QeoEV7UuFxidiwZ3DG0+m6RW3Yi5mOb VHfxOB+NFJ9nN7IbAN3nbLOG1+4uRZ7dM880s3j2OnHF8gEE9Sftd5AfRQ/F41fhmIBg XfuQ== X-Gm-Message-State: AOJu0Yy2n2IU0oCqgkOT9mKI0ZJpT1dOu4OspWhBhsCd7QgyFTf8vIcL 9MU4AD4dGJWuLOBzCxkEMGeSPCTBbwHNWjH/0S2eYgtuwrZo8O/vU445+kwjwDYJFkiRLW4anl2 b1coGvgC6QU5BqztVk4Z7TzXdgiMFzuw6DB2E X-Google-Smtp-Source: AGHT+IHGxQhOhvVYJ26JoP9G9IcjXZpGX0Sba5nLvhVo2vRjCsWeyGACwQK6kxDiKByr3DVoFermjO9V2/jx1KNjD2Q= X-Received: by 2002:ac2:4573:0:b0:51e:1bed:13b3 with SMTP id k19-20020ac24573000000b0051e1bed13b3mr5834941lfm.32.1714965762326; Sun, 05 May 2024 20:22:42 -0700 (PDT) MIME-Version: 1.0 References: <8d597bb5-39c8-4544-ad1a-907a79bf4cba@app.fastmail.com> <086da1ef-79dd-448d-b463-01895df2866f@eastlink.ca> <58741215-7c41-4230-8eb5-6556bd969140@app.fastmail.com> <6cfb08f8-ee3d-40fa-be88-cb10882bc1d0@eastlink.ca> In-Reply-To: <6cfb08f8-ee3d-40fa-be88-cb10882bc1d0@eastlink.ca> From: Bart Schaefer Date: Sun, 5 May 2024 20:22:30 -0700 Message-ID: Subject: Re: nesting issue To: Ray Andrews Cc: zsh-users@zsh.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Seq: 29908 Archived-At: X-Loop: zsh-users@zsh.org Errors-To: zsh-users-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-users-request@zsh.org X-no-archive: yes List-Id: List-Help: , List-Subscribe: , List-Unsubscribe: , List-Post: List-Owner: List-Archive: On Sun, May 5, 2024 at 6:51=E2=80=AFPM Ray Andrews = wrote: > > Man ... I dunno, maybe the world needs different sorting logic between Ca= nada and the US but to me it just looks like making trouble. C sort is done in the order of the ASCII values of the characters. Locale-based sorting is intended to match (hardcopy) dictionary order for the represented language. The latter may mean that "A" and "a" both sort before "B" and "b" and so on, whereas ASCII sorts all uppercase letters before all lowercase. Handling of numbers and punctuation relative to letters and numbers may also vary. Sorting usually proceeds left to right by character position, which means e.g. "22" sorts before "4" because ASCII "2" (062) is compared to "4" (064). When you ask for "numeric" sorting, each consecutive series of digits is instead interpreted as an integer that occupies one "position" -- but the strings are still compared position by position, so when comparing "a2" to "10b" the character "a" is compared to the integer "10" and sorts after it. You only get actual numeric ordering for "mixed" alphanumerics when the numbers occupy the same relative positions. Version sorting is yet another thing entirely, see Functions/Misc/is-at-least for example.