Skip Menu |
 

This queue is for tickets about the Perl-Tidy CPAN distribution.

Report information
The Basics
Id: 125497
Status: open
Priority: 0/
Queue: Perl-Tidy

People
Owner: Nobody in particular
Requestors: rkleemann [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



MIME-Version: 1.0
X-Spam-Status: No, score=-1.84 tagged_above=-99.9 required=10 tests=[AWL=-0.507, BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, SPF_SOFTFAIL=0.665] autolearn=no
X-Cpan.org: This message routed through the cpan.org mail forwarding service. Please use PAUSE pause.perl.org to configure your delivery settings.
X-Spam-Flag: NO
Content-Type: multipart/alternative; boundary="0000000000002eeddf056deb0e23"
Message-ID: <CAO6cO5-GY5n6Wb4wJ9YN=HxOj3x+HudKJ7pf6VB-VfjLAVXh5Q [...] mail.gmail.com>
X-Received: by 2002:a0c:d1f7:: with SMTP id k52-v6mr168217qvh.199.1528231206250; Tue, 05 Jun 2018 13:40:06 -0700 (PDT)
X-Virus-Scanned: Debian amavisd-new at bestpractical.com
X-Spam-Score: -1.84
Received: from localhost (localhost [127.0.0.1]) by hipster.bestpractical.com (Postfix) with ESMTP id 3645A240398 for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Tue, 5 Jun 2018 16:40:41 -0400 (EDT)
Received: from hipster.bestpractical.com ([127.0.0.1]) by localhost (hipster.bestpractical.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id XkQiExbbK-AV for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Tue, 5 Jun 2018 16:40:40 -0400 (EDT)
Received: from xx1.develooper.com (xx1.develooper.com [207.171.7.115]) by hipster.bestpractical.com (Postfix) with ESMTPS id 351FD240343 for <bug-Perl-Tidy [...] rt.cpan.org>; Tue, 5 Jun 2018 16:40:38 -0400 (EDT)
Received: from localhost (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with ESMTP id 3594266FF9 for <bug-Perl-Tidy [...] rt.cpan.org>; Tue, 5 Jun 2018 13:40:37 -0700 (PDT)
Received: from xx1.develooper.com (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with SMTP id F0AC167067 for <bug-Perl-Tidy [...] rt.cpan.org>; Tue, 5 Jun 2018 13:40:33 -0700 (PDT)
Received: from mail-qt0-f179.google.com (mail-qt0-f179.google.com [209.85.216.179]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by xx1.develooper.com (Postfix) with ESMTPS id 1ACDD66FFA for <bug-Perl-Tidy [...] rt.cpan.org>; Tue, 5 Jun 2018 13:40:31 -0700 (PDT)
Received: by mail-qt0-f179.google.com with SMTP id h5-v6so3970260qtm.13 for <bug-Perl-Tidy [...] rt.cpan.org>; Tue, 05 Jun 2018 13:40:31 -0700 (PDT)
Authentication-Results: hipster.bestpractical.com (amavisd-new); dkim=pass header.i= [...] gmail.com
X-Google-SMTP-Source: ADUXVKIls09NNxTQNJ2hXSpba9Bqqba+/eOoLWGaj/LlfCmdIYpbUzuTsH3CbYZNeofuUt56md5QHxAsbcDsSGwq53Q=
Delivered-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
Subject: Support aligning numbers correctly
Return-Path: <rkleemann [...] gmail.com>
X-RT-Mail-Extension: perl-tidy
X-Original-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=nmHQoPijD3i3d4XgkrbCrICqu7kHRB5nIuYnpgiTIWw=; b=hU+5LpdB60vlhMMn+BaB8aLQq3KJ3KQLfQftkJr3dSuoXBn5ixljLEQl/D5+LzDGy9 /pAAnPNhLcl6lvFtFpfuPaIlKSY7/ys4Cz1c+K1/ekSXUwkgL8k9pHbfasKA6sYFFaS3 b+FMRx1ZFbW9XJemfrAiOXzQpvo6/SXl9f2OoPA0j5g6VZr+cuYjmEmajTywWjieL0q6 CpgVFNsKegklkBc+WTG9ta8zU9nfQYhBKF6i+JoCJvHHRNvBPZXAmLvtR5gAvjpovGiF kPNLqEPeIZ3f8DZX51ESNTgBvbapRjouB9iPtRamVWyrfiH8BcyUa0unUBu9v7BFbykK MhUA==
X-Google-Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=nmHQoPijD3i3d4XgkrbCrICqu7kHRB5nIuYnpgiTIWw=; b=EjypN3o4NJv3vTpoHTDr5Exc8s2lLa4fw/UN+8EMHHKnbOGrOKjLc1gp84G+jo9KxR iJHlTFGnXoHBq8H/p8gl2U7qTGU0IRVQlTIoLCjbgkt5Q0VmCLj+5JcUNRHirKrd+k70 Xo6o+ENLtgJWNVgNMqCcp9W8dwVlZQ/09nLzA67snm8bj2b0Ug383QBxIyeK3e57bSk9 v/5rrTp9nOUU5SgB1vVjAU70CQul+XRFTtfSPdvYg1aYmSpPaGUcAUJ/9DfrogtH/E0q 25sVWQ9m+khAstQ5BF//bIdU8dzU8cDA3xOwNblMa8/5N7cYHjldVQw1F5dofRhGAhSu Cyyg==
X-PMX-Spam: Gauge=IIIIIIII, Probability=8%, Report=' HTML_50_70 0.1, HTML_NO_HTTP 0.1, BODYTEXTH_SIZE_10000_LESS 0, BODYTEXTP_SIZE_3000_LESS 0, BODY_SIZE_3000_3999 0, BODY_SIZE_5000_LESS 0, BODY_SIZE_7000_LESS 0, DATE_TZ_NA 0, DKIM_SIGNATURE 0, NO_CTA_URI_FOUND 0, NO_URI_FOUND 0, NO_URI_HTTPS 0, SPF_PASS 0, WEBMAIL_SOURCE 0, __CT 0, __CTYPE_HAS_BOUNDARY 0, __CTYPE_MULTIPART 0, __CTYPE_MULTIPART_ALT 0, __DQ_NEG_HEUR 0, __DQ_NEG_IP 0, __FRAUD_MONEY_CURRENCY 0, __FRAUD_MONEY_CURRENCY_DOLLAR 0, __FRAUD_WEBMAIL 0, __FRAUD_WEBMAIL_FROM 0, __FROM_GMAIL 0, __FUR_RDNS_GMAIL 0, __HAS_FROM 0, __HAS_HTML 0, __HAS_MSGID 0, __HELO_GMAIL 0, __HEX28_LC_BOUNDARY 0, __HIGHBITS 0, __HTML_TAG_DIV 0, __MIME_HTML 0, __MIME_TEXT_H 0, __MIME_TEXT_H1 0, __MIME_TEXT_H2 0, __MIME_TEXT_P 0, __MIME_TEXT_P1 0, __MIME_TEXT_P2 0, __MIME_VERSION 0, __PHISH_SPEAR_SUBJ_TEAM 0, __RDNS_WEBMAIL 0, __SANE_MSGID 0, __STOCK_PHRASE_1 0, __SUBJ_ALPHA_END 0, __TO_MALFORMED_2 0, __TO_NO_NAME 0, __YOUTUBE_RCVD 0, __zen.spamhaus.org_ERROR '
Date: Tue, 5 Jun 2018 13:39:54 -0700
X-Spam-Level:
X-PMX-Version: 5.6.1.2065439, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2018.6.5.203016
To: bug-Perl-Tidy [...] rt.cpan.org
From: Bob Kleemann <rkleemann [...] gmail.com>
X-GM-Message-State: APt69E042nMkjgbetNwZN7W4EGiQjpoLjjid7+FxlviQG80qr954Ra1q kTZcoRGt3tYmVnlKWEC9O7XwK/RlH9ywb5tawQmsRYOs
X-RT-Interface: Email
Content-Length: 0
content-type: text/plain; charset="utf-8"
X-RT-Original-Encoding: utf-8
Content-Length: 769
Download (untitled) / with headers
text/plain 769b
It would be nice if numbers were aligned in a sensible way, on the decimal point. Currently, all numbers are left-aligned, which makes sense in the simple case, but it would be nice if the following code aligned properly: my $price = 102.99; my $adjustment = -2.99; my $tax = 1.0775; my $final = ( $price + $adjustment ) * $tax; Of course, there is some question about how to align some of the more elaborate number formats: my $avagadro = 6.022140857E23; my $YYYYddd = 2018.156; my $pi = 3.14159265; my $green = 0x00ff00; my $rwxrw_rw_ = 0766; my $escape = 0b00011011; I think I've aligned them in a way that makes sense here, but I could see arguments for other alignments. Bob
content-type: text/html; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
X-RT-Original-Encoding: utf-8
Content-Length: 1722
MIME-Version: 1.0
X-Spam-Status: No, score=-4.8 tagged_above=-99.9 required=10 tests=[AWL=-0.467, BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, FREEMAIL_REPLY=1, FROM_OUR_RT=-4, HTML_MESSAGE=0.001, SPF_SOFTFAIL=0.665] autolearn=ham
In-Reply-To: <rt-4.0.18-28629-1528231242-335.125497-4-0 [...] rt.cpan.org>
X-Cpan.org: This message routed through the cpan.org mail forwarding service. Please use PAUSE pause.perl.org to configure your delivery settings.
X-Spam-Flag: NO
X-RT-Interface: API
References: <RT-Ticket-125497 [...] rt.cpan.org> <CAO6cO5-GY5n6Wb4wJ9YN=HxOj3x+HudKJ7pf6VB-VfjLAVXh5Q [...] mail.gmail.com> <rt-4.0.18-28629-1528231242-335.125497-4-0 [...] rt.cpan.org>
X-Virus-Scanned: Debian amavisd-new at bestpractical.com
X-Received: by 2002:a2e:5591:: with SMTP id g17-v6mr2342681lje.4.1528293442772; Wed, 06 Jun 2018 06:57:22 -0700 (PDT)
Message-ID: <CAK7Dq6WQNw+FESQcA7UpV_2oCUoT6CJv+ApQA9V7HfrGrnPJ7A [...] mail.gmail.com>
Content-Type: multipart/alternative; boundary="000000000000c4e71e056df98bee"
X-Spam-Score: -4.8
X-Google-SMTP-Source: ADUXVKJH+MOm/1TRWdXFKVcLqIYGAbtGLK3SNQh6qfKTNICgWfhRtGN3G7rK8xRR/t1SnDBcn0jH1s4ZlqXpTDTAgUY=
Authentication-Results: hipster.bestpractical.com (amavisd-new); dkim=pass header.i= [...] gmail.com
Received: from localhost (localhost [127.0.0.1]) by hipster.bestpractical.com (Postfix) with ESMTP id 8318224037A for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Wed, 6 Jun 2018 09:57:39 -0400 (EDT)
Received: from hipster.bestpractical.com ([127.0.0.1]) by localhost (hipster.bestpractical.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aaAw9TPgF62j for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Wed, 6 Jun 2018 09:57:37 -0400 (EDT)
Received: from xx1.develooper.com (xx1.develooper.com [207.171.7.115]) by hipster.bestpractical.com (Postfix) with ESMTPS id 6D13D24036F for <bug-Perl-Tidy [...] rt.cpan.org>; Wed, 6 Jun 2018 09:57:37 -0400 (EDT)
Received: from localhost (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with ESMTP id 416841202BE for <bug-Perl-Tidy [...] rt.cpan.org>; Wed, 6 Jun 2018 06:57:35 -0700 (PDT)
Received: from xx1.develooper.com (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with SMTP id B0A3F12035B for <bug-Perl-Tidy [...] rt.cpan.org>; Wed, 6 Jun 2018 06:57:32 -0700 (PDT)
Received: from mail-lf0-f52.google.com (mail-lf0-f52.google.com [209.85.215.52]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by xx1.develooper.com (Postfix) with ESMTPS id AFBA01202BE for <bug-Perl-Tidy [...] rt.cpan.org>; Wed, 6 Jun 2018 06:57:24 -0700 (PDT)
Received: by mail-lf0-f52.google.com with SMTP id y20-v6so9307601lfy.0 for <bug-Perl-Tidy [...] rt.cpan.org>; Wed, 06 Jun 2018 06:57:24 -0700 (PDT)
Received: by 2002:a2e:29c3:0:0:0:0:0 with HTTP; Wed, 6 Jun 2018 06:57:22 -0700 (PDT)
Delivered-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
Subject: Re: [rt.cpan.org #125497] Support aligning numbers correctly
Return-Path: <s7078hancock [...] gmail.com>
Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=4gx2y6vrkz9dwWSH0SMgH8DtssxUiRNoByaX1vFFQUA=; b=vatwbb+CJ2hu1QaO3Zhi4mU+R6vvhtjEUIEnznjYzHglzSE/5yqasbdu3XDzAMMQNk 8RGCsyrBIOYVIDOUJANNxxboXuvO/PJv17Rp4lPG97EyrpV84oh1LBM5kQx882/rm5XJ YBnS46VYh9RcDAlyHjfvGFPmqIB73ZgBB2kRjotoQ7qe/2UuDhuaZIoWZO5ye4eYAxxJ HYKQj8Hs6sijuQFP1NIb5ssflxhenFxibkWXSolH0ZkNhrqyTEMAcLu0R3MbmdF7C4Sk L/ZCb87JPZ5ch+P8MGae6ymIIJEGo3UZIVAnhjFnual3UhHqQkuvjlIFHAQDJIGl2nq4 seDg==
X-Original-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
X-RT-Mail-Extension: perl-tidy
X-Google-Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=4gx2y6vrkz9dwWSH0SMgH8DtssxUiRNoByaX1vFFQUA=; b=rSvGMl34cIMlZYpR157kPrO2BjIfeLwJy/i/ARpy27FoDrBznJnJqUwu0tKGgBBUOr NZdH/d0DB9XgJe9UO35OVARCuZDsPJ08Dn8LIM5h9mSyedisk2LBELL/0xF2OhtiruyQ AezNgdeaTmRBZ6SO8jAwsdJnVON3U+TAWNkRVH9fW61t3V5Aiki1BJUgvVO0udkXEdc2 C8zNLKEYgDznKlULhItGFJb1isrGnTh7OaoaBEsNsMHclyi9AZQoQniAJ5Xc18t22VYK ld6MZpYhmu/je8ypeQEe0XoJ26m3DGCfHWNmiHxpa/JWGneXw5xYLsu6k0aPW6Qh54Ag LAQg==
Date: Wed, 6 Jun 2018 06:57:22 -0700
X-PMX-Spam: Gauge=IIIIIIII, Probability=8%, Report=' BODYTEXTH_SIZE_10000_LESS 0, BODYTEXTP_SIZE_3000_LESS 0, BODY_SIZE_4000_4999 0, BODY_SIZE_5000_LESS 0, BODY_SIZE_7000_LESS 0, DATE_TZ_NA 0, DKIM_SIGNATURE 0, IN_REP_TO 0, LEGITIMATE_SIGNS 0, MSG_THREAD 0, REFERENCES 0, SPF_PASS 0, URI_ENDS_IN_HTML 0, WEBMAIL_SOURCE 0, __ANY_URI 0, __BOUNCE_CHALLENGE_SUBJ 0, __BOUNCE_NDR_SUBJ_EXEMPT 0, __CP_URI_IN_BODY 0, __CT 0, __CTYPE_HAS_BOUNDARY 0, __CTYPE_MULTIPART 0, __CTYPE_MULTIPART_ALT 0, __DQ_NEG_HEUR 0, __DQ_NEG_IP 0, __FORWARDED_MSG 0, __FRAUD_BODY_WEBMAIL 0, __FRAUD_MONEY_CURRENCY 0, __FRAUD_MONEY_CURRENCY_DOLLAR 0, __FRAUD_WEBMAIL 0, __FRAUD_WEBMAIL_FROM 0, __FROM_GMAIL 0, __FUR_RDNS_GMAIL 0, __HAS_FROM 0, __HAS_HTML 0, __HAS_MSGID 0, __HELO_GMAIL 0, __HEX28_LC_BOUNDARY 0, __HIGHBITS 0, __HTML_AHREF_TAG 0, __HTML_TAG_DIV 0, __HTTPS_URI 0, __IN_REP_TO 0, __MIME_HTML 0, __MIME_TEXT_H 0, __MIME_TEXT_H1 0, __MIME_TEXT_H2 0, __MIME_TEXT_P 0, __MIME_TEXT_P1 0, __MIME_TEXT_P2 0, __MIME_VERSION 0, __MULTIPLE_URI_TEXT 0, __PHISH_FROM 0, __PHISH_FROM2 0, __PHISH_SPEAR_HTTP_RECEIVED 0, __PHISH_SPEAR_STRUCTURE_1 0, __PHISH_SPEAR_SUBJ_TEAM 0, __RATWARE_SIGNATURE_3_N1 0, __RDNS_WEBMAIL 0, __REFERENCES 0, __SANE_MSGID 0, __STOCK_PHRASE_1 0, __SUBJ_ALPHA_END 0, __SUBJ_ALPHA_NEGATE 0, __SUBJ_REPLY 0, __TO_MALFORMED_2 0, __TO_NO_NAME 0, __URI_IN_BODY 0, __URI_NOT_IMG 0, __URI_NO_WWW 0, __URI_NS , __URI_WITHOUT_PATH 0, __URI_WITH_PATH 0, __YOUTUBE_RCVD 0, __zen.spamhaus.org_ERROR '
X-Spam-Level:
X-PMX-Version: 5.6.1.2065439, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2018.6.6.135416
To: bug-Perl-Tidy [...] rt.cpan.org
X-GM-Message-State: APt69E2o0VRiW3ZojxVNhupugllKmHP+94mf+WMBSOQiSDqSsylca3mv YegmibwV9dFmhyV5XjnhGrJ19pmYLCSejif25p1lGQ==
From: Steven Hancock <s7078hancock [...] gmail.com>
RT-Message-ID: <rt-4.0.18-369-1528293460-865.125497-0-0 [...] rt.cpan.org>
Content-Length: 0
content-type: text/plain; charset="utf-8"
X-RT-Original-Encoding: utf-8
Content-Length: 1504
Download (untitled) / with headers
text/plain 1.4k
Bob, Thanks for the suggestion. This could also be useful for large tables of values. I did look into it at one time but found that there were so many possible variations that it was hard to code. Steve On Tue, Jun 5, 2018 at 1:40 PM, Bob Kleemann via RT < bug-Perl-Tidy@rt.cpan.org> wrote: Show quoted text
> Tue Jun 05 16:40:42 2018: Request 125497 was acted upon. > Transaction: Ticket created by rkleemann@gmail.com > Queue: Perl-Tidy > Subject: Support aligning numbers correctly > Broken in: (no value) > Severity: (no value) > Owner: Nobody > Requestors: rkleemann@gmail.com > Status: new > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=125497 > > > > It would be nice if numbers were aligned in a sensible way, on the decimal > point. Currently, all numbers are left-aligned, which makes sense in the > simple case, but it would be nice if the following code aligned properly: > > my $price = 102.99; > my $adjustment = -2.99; > my $tax = 1.0775; > my $final = ( $price + $adjustment ) * $tax; > > > Of course, there is some question about how to align some of the more > elaborate number formats: > > my $avagadro = 6.022140857E23; > my $YYYYddd = 2018.156; > my $pi = 3.14159265; > > my $green = 0x00ff00; > my $rwxrw_rw_ = 0766; > my $escape = 0b00011011; > > > I think I've aligned them in a way that makes sense here, but I could see > arguments for other alignments. > > Bob > >
content-type: text/html; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
X-RT-Original-Encoding: utf-8
Content-Length: 2272
MIME-Version: 1.0
X-Spam-Status: No, score=-3.739 tagged_above=-99.9 required=10 tests=[AWL=1.594, BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, FROM_OUR_RT=-4, HTML_MESSAGE=0.001, SPF_SOFTFAIL=0.665] autolearn=ham
In-Reply-To: <rt-4.0.18-369-1528293460-290.125497-6-0 [...] rt.cpan.org>
X-Cpan.org: This message routed through the cpan.org mail forwarding service. Please use PAUSE pause.perl.org to configure your delivery settings.
X-Spam-Flag: NO
X-RT-Interface: API
References: <RT-Ticket-125497 [...] rt.cpan.org> <CAO6cO5-GY5n6Wb4wJ9YN=HxOj3x+HudKJ7pf6VB-VfjLAVXh5Q [...] mail.gmail.com> <rt-4.0.18-28629-1528231242-335.125497-4-0 [...] rt.cpan.org> <CAK7Dq6WQNw+FESQcA7UpV_2oCUoT6CJv+ApQA9V7HfrGrnPJ7A [...] mail.gmail.com> <rt-4.0.18-369-1528293460-290.125497-6-0 [...] rt.cpan.org>
X-Virus-Scanned: Debian amavisd-new at bestpractical.com
X-Received: by 2002:a0c:f149:: with SMTP id y9-v6mr3412079qvl.111.1528304574173; Wed, 06 Jun 2018 10:02:54 -0700 (PDT)
Message-ID: <CAO6cO5--pjEpjHyXXVSoz5KN6CcwmcZdH9Hu5z5scgg7y77BNQ [...] mail.gmail.com>
Content-Type: multipart/alternative; boundary="000000000000409743056dfc2307"
X-Spam-Score: -3.739
X-Google-SMTP-Source: ADUXVKLsi0XUDhPpl/Mv1UweF1hnDXACTOb0sk84p8/bETl1Fzaklae7xrVR9LLc0SOT8Cs61CvKZeGsO+zvIgh8GAk=
Authentication-Results: hipster.bestpractical.com (amavisd-new); dkim=pass header.i= [...] gmail.com
Received: from localhost (localhost [127.0.0.1]) by hipster.bestpractical.com (Postfix) with ESMTP id 63FD5240208 for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Wed, 6 Jun 2018 13:04:34 -0400 (EDT)
Received: from hipster.bestpractical.com ([127.0.0.1]) by localhost (hipster.bestpractical.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JMToQTB3Tau7 for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Wed, 6 Jun 2018 13:04:31 -0400 (EDT)
Received: from xx1.develooper.com (xx1.develooper.com [207.171.7.115]) by hipster.bestpractical.com (Postfix) with ESMTPS id 537662400D1 for <bug-Perl-Tidy [...] rt.cpan.org>; Wed, 6 Jun 2018 13:04:31 -0400 (EDT)
Received: from localhost (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with ESMTP id DB56211F639 for <bug-Perl-Tidy [...] rt.cpan.org>; Wed, 6 Jun 2018 10:04:29 -0700 (PDT)
Received: from xx1.develooper.com (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with SMTP id C550A11F636 for <bug-Perl-Tidy [...] rt.cpan.org>; Wed, 6 Jun 2018 10:04:24 -0700 (PDT)
Received: from mail-qt0-f181.google.com (mail-qt0-f181.google.com [209.85.216.181]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by xx1.develooper.com (Postfix) with ESMTPS id 5151911F639 for <bug-Perl-Tidy [...] rt.cpan.org>; Wed, 6 Jun 2018 10:02:55 -0700 (PDT)
Received: by mail-qt0-f181.google.com with SMTP id y31-v6so7082703qty.9 for <bug-Perl-Tidy [...] rt.cpan.org>; Wed, 06 Jun 2018 10:02:55 -0700 (PDT)
Delivered-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
Subject: Re: [rt.cpan.org #125497] Support aligning numbers correctly
Return-Path: <rkleemann [...] gmail.com>
Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=GfZHTJBtNEjTvgSAqt7oY99ythdn6diCJyTWHeHmeZo=; b=Y18dZpuMANdENEOJUF6aOLTijXskbIj/NL0HZEDG5QWDkL95P+vZ1rQHrK9V8yjImR EJfTjvL+QF3IMMkmf+YPRoGj5qsyOO24d9nOWWoXZ7L8rdedc0yO2Es14lIQRo8klavE 4B9T4cyt+vug3diuiDpxTBlMYlo/ZjnqhQlZhV5sBTkDVi9DXUxYC43QUd4nJwTTXL3R m9wDNngkMNbExVwuU5R0r348QAHbBfP6RofGL8mnJoHNlwCl4ROsLX+EngC6m/CzdqEi v9ivwfc482OY2oA9yIXIRD5m3I481r0c4CyY2yVyGxdIGgOmvM8+1l9JeQg8kApwclnT 4RRw==
X-Original-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
X-RT-Mail-Extension: perl-tidy
X-Google-Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=GfZHTJBtNEjTvgSAqt7oY99ythdn6diCJyTWHeHmeZo=; b=Kpj12WStIcFynVHu2TZfy7Xxa9illXh1I5sh1lzmBdR4jzf/sGWXgqpSL71UmGbHci 5+gTj4Y2Rd4t6v4lTF+PJUMaKVFSwNGiWxdSUPrp6gw5M31riGqC7EtWrLxDSYveilwx cAkTnOYkwkkBPpaswpuSKllpBIcBFfHvrLNR0aGHGCW0WKhGVwLTtrwl7iKgx7BgAzTL LeEjZbOe4iTGMCjOXe0gx16NrcF8GdyxaH68A3jzaOwmWjBFbjY0GlB3xjEH9XRRkCZm 3Ep1u/yivVdktMsq2qb5+akMzy/Xp3MMKZcZj1BDijUjSEuy8LYbgVsI7OXfbRqYiJEh M0vw==
Date: Wed, 6 Jun 2018 10:02:42 -0700
X-PMX-Spam: Gauge=IIIIIIII, Probability=8%, Report=' BODYTEXTH_SIZE_10000_LESS 0, BODYTEXTH_SIZE_3000_MORE 0, BODYTEXTP_SIZE_3000_LESS 0, BODY_SIZE_6000_6999 0, BODY_SIZE_7000_LESS 0, DATE_TZ_NA 0, DKIM_SIGNATURE 0, IN_REP_TO 0, LEGITIMATE_SIGNS 0, MSG_THREAD 0, REFERENCES 0, SPF_PASS 0, URI_ENDS_IN_HTML 0, WEBMAIL_SOURCE 0, __ANY_URI 0, __BOUNCE_CHALLENGE_SUBJ 0, __BOUNCE_NDR_SUBJ_EXEMPT 0, __CP_URI_IN_BODY 0, __CT 0, __CTYPE_HAS_BOUNDARY 0, __CTYPE_MULTIPART 0, __CTYPE_MULTIPART_ALT 0, __DQ_NEG_HEUR 0, __DQ_NEG_IP 0, __FORWARDED_MSG 0, __FRAUD_BODY_WEBMAIL 0, __FRAUD_MONEY_CURRENCY 0, __FRAUD_MONEY_CURRENCY_DOLLAR 0, __FRAUD_WEBMAIL 0, __FRAUD_WEBMAIL_FROM 0, __FROM_GMAIL 0, __FUR_RDNS_GMAIL 0, __HAS_FROM 0, __HAS_HTML 0, __HAS_MSGID 0, __HELO_GMAIL 0, __HEX28_LC_BOUNDARY 0, __HIGHBITS 0, __HTML_AHREF_TAG 0, __HTML_TAG_DIV 0, __HTTPS_URI 0, __IN_REP_TO 0, __MIME_HTML 0, __MIME_TEXT_H 0, __MIME_TEXT_H1 0, __MIME_TEXT_H2 0, __MIME_TEXT_P 0, __MIME_TEXT_P1 0, __MIME_TEXT_P2 0, __MIME_VERSION 0, __MULTIPLE_URI_HTML 0, __MULTIPLE_URI_TEXT 0, __PHISH_SPEAR_SUBJ_TEAM 0, __RDNS_WEBMAIL 0, __REFERENCES 0, __SANE_MSGID 0, __STOCK_PHRASE_1 0, __SUBJ_ALPHA_END 0, __SUBJ_ALPHA_NEGATE 0, __SUBJ_REPLY 0, __TO_MALFORMED_2 0, __TO_NO_NAME 0, __URI_IN_BODY 0, __URI_NOT_IMG 0, __URI_NO_WWW 0, __URI_NS , __URI_WITHOUT_PATH 0, __URI_WITH_PATH 0, __YOUTUBE_RCVD 0, __zen.spamhaus.org_ERROR '
X-Spam-Level:
X-PMX-Version: 5.6.1.2065439, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2018.4.8.232716
To: bug-Perl-Tidy [...] rt.cpan.org
X-GM-Message-State: APt69E3PfTMCqHHPSXBfo5SgzBVQbAGXkeSrTWuLulWriq7mbpp14eam 4JSHolagc9mjrnuWrm2r7Sbr0mSASoEuZiAk6iqeCg==
From: Bob Kleemann <rkleemann [...] gmail.com>
RT-Message-ID: <rt-4.0.18-4675-1528304675-1781.125497-0-0 [...] rt.cpan.org>
Content-Length: 0
content-type: text/plain; charset="utf-8"
X-RT-Original-Encoding: utf-8
Content-Length: 2249
Download (untitled) / with headers
text/plain 2.1k
How many variations are there? Integers (a series of numbers that does not start with 0), decimal (a series of numbers followed by period, followed by another series of numbers), floating point (a decimal, followed by an 'e', followed by an integer), binary/octal/hex, and I think that's it. All of the values should be aligned on the single units or the period, except the binary/octal/hex, which should be aligned on the leading 0 (in my opinion, I can see discussion on that point). On Wed, Jun 6, 2018 at 6:58 AM Steven Hancock via RT < bug-Perl-Tidy@rt.cpan.org> wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=125497 > > > Bob, > Thanks for the suggestion. This could also be useful for large tables of > values. > I did look into it at one time but found that there were so many > possible variations that it was hard to code. > Steve > > On Tue, Jun 5, 2018 at 1:40 PM, Bob Kleemann via RT < > bug-Perl-Tidy@rt.cpan.org> wrote: >
> > Tue Jun 05 16:40:42 2018: Request 125497 was acted upon. > > Transaction: Ticket created by rkleemann@gmail.com > > Queue: Perl-Tidy > > Subject: Support aligning numbers correctly > > Broken in: (no value) > > Severity: (no value) > > Owner: Nobody > > Requestors: rkleemann@gmail.com > > Status: new > > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=125497 > > > > > > > It would be nice if numbers were aligned in a sensible way, on the
> decimal
> > point. Currently, all numbers are left-aligned, which makes sense in the > > simple case, but it would be nice if the following code aligned properly: > > > > my $price = 102.99; > > my $adjustment = -2.99; > > my $tax = 1.0775; > > my $final = ( $price + $adjustment ) * $tax; > > > > > > Of course, there is some question about how to align some of the more > > elaborate number formats: > > > > my $avagadro = 6.022140857E23; > > my $YYYYddd = 2018.156; > > my $pi = 3.14159265; > > > > my $green = 0x00ff00; > > my $rwxrw_rw_ = 0766; > > my $escape = 0b00011011; > > > > > > I think I've aligned them in a way that makes sense here, but I could see > > arguments for other alignments. > > > > Bob > > > >
> >
content-type: text/html; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
X-RT-Original-Encoding: utf-8
Content-Length: 3208
MIME-Version: 1.0
X-Spam-Status: No, score=-4.788 tagged_above=-99.9 required=10 tests=[AWL=-0.455, BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, FREEMAIL_REPLY=1, FROM_OUR_RT=-4, HTML_MESSAGE=0.001, SPF_SOFTFAIL=0.665] autolearn=ham
In-Reply-To: <rt-4.0.18-4675-1528304676-851.125497-5-0 [...] rt.cpan.org>
X-Cpan.org: This message routed through the cpan.org mail forwarding service. Please use PAUSE pause.perl.org to configure your delivery settings.
X-Spam-Flag: NO
X-RT-Interface: API
References: <RT-Ticket-125497 [...] rt.cpan.org> <CAO6cO5-GY5n6Wb4wJ9YN=HxOj3x+HudKJ7pf6VB-VfjLAVXh5Q [...] mail.gmail.com> <rt-4.0.18-28629-1528231242-335.125497-4-0 [...] rt.cpan.org> <CAK7Dq6WQNw+FESQcA7UpV_2oCUoT6CJv+ApQA9V7HfrGrnPJ7A [...] mail.gmail.com> <rt-4.0.18-369-1528293460-290.125497-6-0 [...] rt.cpan.org> <CAO6cO5--pjEpjHyXXVSoz5KN6CcwmcZdH9Hu5z5scgg7y77BNQ [...] mail.gmail.com> <rt-4.0.18-4675-1528304676-851.125497-5-0 [...] rt.cpan.org>
X-Virus-Scanned: Debian amavisd-new at bestpractical.com
X-Received: by 2002:a19:20c1:: with SMTP id g184-v6mr1528701lfg.96.1528381480007; Thu, 07 Jun 2018 07:24:40 -0700 (PDT)
Message-ID: <CAK7Dq6Ui+UvT0LaRmex0jVqJ=BmUE-L0+817Y7t80Ou-qUUzJQ [...] mail.gmail.com>
Content-Type: multipart/alternative; boundary="000000000000327ac6056e0e0b5f"
X-Spam-Score: -4.788
X-Google-SMTP-Source: ADUXVKJWGurU4QNb+YcnTrqw/ETYPoqans6aK9Diin1ZQBThezQbqFCi9mtzC5yIHnf3YV8FMCNaD/JL7DQlfcc6CXg=
Authentication-Results: hipster.bestpractical.com (amavisd-new); dkim=pass header.i= [...] gmail.com
Received: from localhost (localhost [127.0.0.1]) by hipster.bestpractical.com (Postfix) with ESMTP id D6908240353 for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Thu, 7 Jun 2018 10:24:51 -0400 (EDT)
Received: from hipster.bestpractical.com ([127.0.0.1]) by localhost (hipster.bestpractical.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ls3+9E8VBu5L for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Thu, 7 Jun 2018 10:24:49 -0400 (EDT)
Received: from xx1.develooper.com (xx1.develooper.com [207.171.7.115]) by hipster.bestpractical.com (Postfix) with ESMTPS id 54F9A24020A for <bug-Perl-Tidy [...] rt.cpan.org>; Thu, 7 Jun 2018 10:24:49 -0400 (EDT)
Received: from localhost (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with ESMTP id B3876121591 for <bug-Perl-Tidy [...] rt.cpan.org>; Thu, 7 Jun 2018 07:24:47 -0700 (PDT)
Received: from xx1.develooper.com (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with SMTP id B349866FF9 for <bug-Perl-Tidy [...] rt.cpan.org>; Thu, 7 Jun 2018 07:24:44 -0700 (PDT)
Received: from mail-lf0-f52.google.com (mail-lf0-f52.google.com [209.85.215.52]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by xx1.develooper.com (Postfix) with ESMTPS id 1350B12161D for <bug-Perl-Tidy [...] rt.cpan.org>; Thu, 7 Jun 2018 07:24:42 -0700 (PDT)
Received: by mail-lf0-f52.google.com with SMTP id n3-v6so14985761lfe.12 for <bug-Perl-Tidy [...] rt.cpan.org>; Thu, 07 Jun 2018 07:24:42 -0700 (PDT)
Received: by 2002:a2e:2188:0:0:0:0:0 with HTTP; Thu, 7 Jun 2018 07:24:39 -0700 (PDT)
Delivered-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
Subject: Re: [rt.cpan.org #125497] Support aligning numbers correctly
Return-Path: <s7078hancock [...] gmail.com>
Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=iUUy33HIIfxzFVJXN0WafnjrCFs1A8bDCLTNTjwSOkQ=; b=JVBANJixTAnop6n/epZvcWPP9Y+/QkSj/rFW1ytMYQH0/dABIm5MDftEQ7f0WMewDq F+x96Ve7mW0LQUT/tjUwjBVNtUpyFUB2NmWZ66eDZbGfp8jQv6sz0ASl2VlOgBev8IBM D42Jbewqx+J8HpW7PNNi1jc2/wNqQApBB2rBmuvx/83oWqr/VJQgEESB13PXAkeNI9uu SOsDyETc8OcS6K3A16NVVA7ZhHUQOIZBV/9tF4q8fCWMiO6MyZK9SjwWmLVBskwYqEqp FGldK/Vyf1N6pq+rmoaTZl+V4Qu8C/wJJiohjHFnB/vg/2kFJTZjx/Jq3SYTAeBCFoCb z9Ig==
X-Original-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
X-RT-Mail-Extension: perl-tidy
X-Google-Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=iUUy33HIIfxzFVJXN0WafnjrCFs1A8bDCLTNTjwSOkQ=; b=t7CaZQiu/7YeHO918M7Bpl91YSyl1thoBe8ErDmPNrLwQv3Hc9iLZ/FqDR1b2mO4Oy 52H/dEZ6zr3M0Feq/0v9LHmoE15EDiEThVG15+2DQ+4QJnbalq1DYo01Teo6omB3aEKB sAxfyk86Gk/Jo0oLlh8gFPOZTXuYEujBfskVWvB4VqyU9908RcDILLDYoQZJLq9M95nh kJaHXJLENRntQqVoYDnqQTBc4PAnztlOE839oY2HRqgRJ8/jzgB07IIz+2nREstsv+b3 zbZJel7gNwKEdjYe3l2FIOxgf8Jcqbht1gA3POF8nG1lTW9NwZ/zV48k1KJ9n+ypXHgE PBBQ==
Date: Thu, 7 Jun 2018 07:24:39 -0700
X-PMX-Spam: Gauge=IIIIIIII, Probability=8%, Report=' BODYTEXTH_SIZE_10000_LESS 0, BODYTEXTH_SIZE_3000_MORE 0, BODY_SIZE_10000_PLUS 0, DATE_TZ_NA 0, DKIM_SIGNATURE 0, IN_REP_TO 0, LEGITIMATE_SIGNS 0, MSG_THREAD 0, REFERENCES 0, SPF_PASS 0, URI_ENDS_IN_HTML 0, WEBMAIL_SOURCE 0, __ANY_URI 0, __BOUNCE_CHALLENGE_SUBJ 0, __BOUNCE_NDR_SUBJ_EXEMPT 0, __CP_URI_IN_BODY 0, __CT 0, __CTYPE_HAS_BOUNDARY 0, __CTYPE_MULTIPART 0, __CTYPE_MULTIPART_ALT 0, __DQ_NEG_HEUR 0, __DQ_NEG_IP 0, __FORWARDED_MSG 0, __FRAUD_BODY_WEBMAIL 0, __FRAUD_MONEY_CURRENCY 0, __FRAUD_MONEY_CURRENCY_DOLLAR 0, __FRAUD_WEBMAIL 0, __FRAUD_WEBMAIL_FROM 0, __FROM_GMAIL 0, __FUR_RDNS_GMAIL 0, __HAS_FROM 0, __HAS_HTML 0, __HAS_MSGID 0, __HELO_GMAIL 0, __HEX28_LC_BOUNDARY 0, __HIGHBITS 0, __HTML_AHREF_TAG 0, __HTML_TAG_DIV 0, __HTTPS_URI 0, __IN_REP_TO 0, __MIME_HTML 0, __MIME_TEXT_H 0, __MIME_TEXT_H1 0, __MIME_TEXT_H2 0, __MIME_TEXT_P 0, __MIME_TEXT_P1 0, __MIME_TEXT_P2 0, __MIME_VERSION 0, __MULTIPLE_URI_HTML 0, __MULTIPLE_URI_TEXT 0, __PHISH_FROM 0, __PHISH_FROM2 0, __PHISH_SPEAR_HTTP_RECEIVED 0, __PHISH_SPEAR_STRUCTURE_1 0, __PHISH_SPEAR_SUBJ_TEAM 0, __RDNS_WEBMAIL 0, __REFERENCES 0, __SANE_MSGID 0, __STOCK_PHRASE_1 0, __SUBJ_ALPHA_END 0, __SUBJ_ALPHA_NEGATE 0, __SUBJ_REPLY 0, __TO_MALFORMED_2 0, __TO_NO_NAME 0, __URI_IN_BODY 0, __URI_NOT_IMG 0, __URI_NO_WWW 0, __URI_NS , __URI_WITHOUT_PATH 0, __URI_WITH_PATH 0, __YOUTUBE_RCVD 0, __zen.spamhaus.org_ERROR '
X-Spam-Level:
X-PMX-Version: 5.6.1.2065439, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2018.6.7.141217
To: bug-Perl-Tidy [...] rt.cpan.org
X-GM-Message-State: APt69E39UkP7xuQbYVUmgfUS4QiUrIbwRWou+bhvLUDmWalNqdXjxyNX cvE8QdVZ4IgI1eDbqJP8hcP9sEGr07g0PrAsIqx8lKOB
From: Steven Hancock <s7078hancock [...] gmail.com>
RT-Message-ID: <rt-4.0.18-18898-1528381492-1665.125497-0-0 [...] rt.cpan.org>
Content-Length: 0
content-type: text/plain; charset="utf-8"
X-RT-Original-Encoding: utf-8
Content-Length: 3488
Download (untitled) / with headers
text/plain 3.4k
Here are some examples of issues that can arise (note: I'm not sure if my original spacing will survive email!) 1. Integers can be a big problem. They may or may not look okay when formatted this way. Consider: my $low = 1; my $delta = 2; my $hi = 101.1; This isn't too bad but it isn't so great either. Consider: my $i = 0; my $conversion_factor = 37458978.21; This doesn't look good at all. 2. It is very common to have additional operations in lists of numbers, and these may pose a problem. Consider my $conversion_factor = 37458978.21; my $conversion_factor2 = 167.22 * 2; This might be okay. But consider my $conversion_factor = 37458978.21; my $pi2 = 3.14159 * 2; my $pi4 = 4 * 3.14159; my $tol = 0.00000025; This is getting hard to read. 3. Adding the extra spaces to align numbers this way in lists may cause an entire list to be expanded in a very undesirable way. On Wed, Jun 6, 2018 at 10:04 AM, Bob Kleemann via RT < bug-Perl-Tidy@rt.cpan.org> wrote: Show quoted text
> Queue: Perl-Tidy > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=125497 > > > How many variations are there? Integers (a series of numbers that does not > start with 0), decimal (a series of numbers followed by period, followed by > another series of numbers), floating point (a decimal, followed by an 'e', > followed by an integer), binary/octal/hex, and I think that's it. All of > the values should be aligned on the single units or the period, except the > binary/octal/hex, which should be aligned on the leading 0 (in my opinion, > I can see discussion on that point). > > On Wed, Jun 6, 2018 at 6:58 AM Steven Hancock via RT < > bug-Perl-Tidy@rt.cpan.org> wrote: >
> > <URL: https://rt.cpan.org/Ticket/Display.html?id=125497 > > > > > Bob, > > Thanks for the suggestion. This could also be useful for large tables of > > values. > > I did look into it at one time but found that there were so many > > possible variations that it was hard to code. > > Steve > > > > On Tue, Jun 5, 2018 at 1:40 PM, Bob Kleemann via RT < > > bug-Perl-Tidy@rt.cpan.org> wrote: > >
> > > Tue Jun 05 16:40:42 2018: Request 125497 was acted upon. > > > Transaction: Ticket created by rkleemann@gmail.com > > > Queue: Perl-Tidy > > > Subject: Support aligning numbers correctly > > > Broken in: (no value) > > > Severity: (no value) > > > Owner: Nobody > > > Requestors: rkleemann@gmail.com > > > Status: new > > > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=125497 > > > > > > > > > > It would be nice if numbers were aligned in a sensible way, on the
> > decimal
> > > point. Currently, all numbers are left-aligned, which makes sense in
> the
> > > simple case, but it would be nice if the following code aligned
> properly:
> > > > > > my $price = 102.99; > > > my $adjustment = -2.99; > > > my $tax = 1.0775; > > > my $final = ( $price + $adjustment ) * $tax; > > > > > > > > > Of course, there is some question about how to align some of the more > > > elaborate number formats: > > > > > > my $avagadro = 6.022140857E23; > > > my $YYYYddd = 2018.156; > > > my $pi = 3.14159265; > > > > > > my $green = 0x00ff00; > > > my $rwxrw_rw_ = 0766; > > > my $escape = 0b00011011; > > > > > > > > > I think I've aligned them in a way that makes sense here, but I could
> see
> > > arguments for other alignments. > > > > > > Bob > > > > > >
> > > >
> >
content-type: text/html; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
X-RT-Original-Encoding: utf-8
Content-Length: 6917
MIME-Version: 1.0
X-Spam-Status: No, score=-4.005 tagged_above=-99.9 required=10 tests=[AWL=1.328, BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, FROM_OUR_RT=-4, HTML_MESSAGE=0.001, SPF_SOFTFAIL=0.665] autolearn=ham
In-Reply-To: <rt-4.0.18-18898-1528381493-408.125497-6-0 [...] rt.cpan.org>
X-Cpan.org: This message routed through the cpan.org mail forwarding service. Please use PAUSE pause.perl.org to configure your delivery settings.
X-Spam-Flag: NO
X-RT-Interface: API
References: <RT-Ticket-125497 [...] rt.cpan.org> <CAO6cO5-GY5n6Wb4wJ9YN=HxOj3x+HudKJ7pf6VB-VfjLAVXh5Q [...] mail.gmail.com> <rt-4.0.18-28629-1528231242-335.125497-4-0 [...] rt.cpan.org> <CAK7Dq6WQNw+FESQcA7UpV_2oCUoT6CJv+ApQA9V7HfrGrnPJ7A [...] mail.gmail.com> <rt-4.0.18-369-1528293460-290.125497-6-0 [...] rt.cpan.org> <CAO6cO5--pjEpjHyXXVSoz5KN6CcwmcZdH9Hu5z5scgg7y77BNQ [...] mail.gmail.com> <rt-4.0.18-4675-1528304676-851.125497-5-0 [...] rt.cpan.org> <CAK7Dq6Ui+UvT0LaRmex0jVqJ=BmUE-L0+817Y7t80Ou-qUUzJQ [...] mail.gmail.com> <rt-4.0.18-18898-1528381493-408.125497-6-0 [...] rt.cpan.org>
X-Virus-Scanned: Debian amavisd-new at bestpractical.com
X-Received: by 2002:ae9:e009:: with SMTP id m9-v6mr2099363qkk.444.1528389075346; Thu, 07 Jun 2018 09:31:15 -0700 (PDT)
Message-ID: <CAO6cO58SNtEqVuwjwW8V_w3kGa9mR_KuZnWhr9BbOtapCUjziw [...] mail.gmail.com>
Content-Type: multipart/alternative; boundary="000000000000ea2af5056e0fcfd7"
X-Spam-Score: -4.005
X-Google-SMTP-Source: ADUXVKKXcGklFJojdchCcqgqpeTlUQSBJpBmrIFrJKKFPhGNfS5MkhnPYYCT5ahgomf240DOp7plGJWK7na+0TUQrZs=
Authentication-Results: hipster.bestpractical.com (amavisd-new); dkim=pass header.i= [...] gmail.com
Received: from localhost (localhost [127.0.0.1]) by hipster.bestpractical.com (Postfix) with ESMTP id A570824033D for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Thu, 7 Jun 2018 12:31:26 -0400 (EDT)
Received: from hipster.bestpractical.com ([127.0.0.1]) by localhost (hipster.bestpractical.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DTxLQ7WAzRzw for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Thu, 7 Jun 2018 12:31:24 -0400 (EDT)
Received: from xx1.develooper.com (xx1.develooper.com [207.171.7.115]) by hipster.bestpractical.com (Postfix) with ESMTPS id CB6DB24020A for <bug-Perl-Tidy [...] rt.cpan.org>; Thu, 7 Jun 2018 12:31:23 -0400 (EDT)
Received: from localhost (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with ESMTP id 1EC76120728 for <bug-Perl-Tidy [...] rt.cpan.org>; Thu, 7 Jun 2018 09:31:23 -0700 (PDT)
Received: from xx1.develooper.com (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with SMTP id 084C212073D for <bug-Perl-Tidy [...] rt.cpan.org>; Thu, 7 Jun 2018 09:31:19 -0700 (PDT)
Received: from mail-qk0-f176.google.com (mail-qk0-f176.google.com [209.85.220.176]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by xx1.develooper.com (Postfix) with ESMTPS id B3C2E120728 for <bug-Perl-Tidy [...] rt.cpan.org>; Thu, 7 Jun 2018 09:31:16 -0700 (PDT)
Received: by mail-qk0-f176.google.com with SMTP id g14-v6so6942267qkm.6 for <bug-Perl-Tidy [...] rt.cpan.org>; Thu, 07 Jun 2018 09:31:16 -0700 (PDT)
Delivered-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
Subject: Re: [rt.cpan.org #125497] Support aligning numbers correctly
Return-Path: <rkleemann [...] gmail.com>
Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=GtU7GiW/tudvENeM1mQNKx+7Vdr7kyPV9Fufu9sf1ZE=; b=ErcZWbvsbiY7KbO75glaWjGkr/bmhJCMyX2T96/YGWgP9iXOh5Pd+BKC6KMEm7pvIF ZUxVjk/k2CanE5TWXwFu1ZTVEnjj5qH5aJYUl8GtKQ9lMJUBvMqtCVlKasbBwFHIKL6b roCxtaZK7GDayQoDhW37XoCNAHu+6et+3u0I/y3GZ3g58Jc9V3bSlgRhJ+dA4+unNPyh 3bp0QBOLQN82teMXblzvuyV7vyQAzGAFXvEY9lIET0UfBckYsyxZzi5zdtzDUkNTKZx2 sw662k1EjnR0uj9eZ94G0d0oBEflv5/sUZYclmodZgI196pP35H+YokrS/s1XZctBYhF TTKg==
X-Original-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
X-RT-Mail-Extension: perl-tidy
X-Google-Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=GtU7GiW/tudvENeM1mQNKx+7Vdr7kyPV9Fufu9sf1ZE=; b=qInIVRh+tyxxaVyjDoyRkax9kYkaZaMNbEsqUL3RGmnt8D9Z9XG4kII9D32x1iHybe lT0m2gbQUp8RfLMzMaWgAZslmQNPoawk/y6EYqEk791I+VBwr3iNVQ2L/KOovzC9v+0G rDJONDm9UmuSf1MWOvJgIJh72/tEyWVhZ6XGWVsQ2dxoKorUPu0aLa8TjJbkY3RYvgb8 ZkhHGEP0HZKjuY+eyyf5ETKslpUPois9yggG0cWMNfdOmcW6RpD/ASzmjZQfv95KwnlI zul/AOFAgodmXDKjIDtbU3R9ig9048AaSR45onzwWvaR+bb502P2FMPYcScFH9fOTx3z Ft6g==
Date: Thu, 7 Jun 2018 09:31:03 -0700
X-PMX-Spam: Gauge=IIIIIIII, Probability=8%, Report=' BODYTEXTH_SIZE_3000_MORE 0, BODY_SIZE_10000_PLUS 0, DATE_TZ_NA 0, DKIM_SIGNATURE 0, IN_REP_TO 0, LEGITIMATE_SIGNS 0, MSG_THREAD 0, REFERENCES 0, SPF_PASS 0, URI_ENDS_IN_HTML 0, WEBMAIL_SOURCE 0, __ANY_URI 0, __BOUNCE_CHALLENGE_SUBJ 0, __BOUNCE_NDR_SUBJ_EXEMPT 0, __CP_URI_IN_BODY 0, __CT 0, __CTYPE_HAS_BOUNDARY 0, __CTYPE_MULTIPART 0, __CTYPE_MULTIPART_ALT 0, __DQ_NEG_HEUR 0, __DQ_NEG_IP 0, __FORWARDED_MSG 0, __FRAUD_BODY_WEBMAIL 0, __FRAUD_MONEY_CURRENCY 0, __FRAUD_MONEY_CURRENCY_DOLLAR 0, __FRAUD_WEBMAIL 0, __FRAUD_WEBMAIL_FROM 0, __FROM_GMAIL 0, __FUR_RDNS_GMAIL 0, __HAS_FROM 0, __HAS_HTML 0, __HAS_MSGID 0, __HELO_GMAIL 0, __HEX28_LC_BOUNDARY 0, __HIGHBITS 0, __HTML_AHREF_TAG 0, __HTML_TAG_DIV 0, __HTTPS_URI 0, __IN_REP_TO 0, __MIME_HTML 0, __MIME_TEXT_H 0, __MIME_TEXT_H1 0, __MIME_TEXT_H2 0, __MIME_TEXT_P 0, __MIME_TEXT_P1 0, __MIME_TEXT_P2 0, __MIME_VERSION 0, __MULTIPLE_URI_HTML 0, __MULTIPLE_URI_TEXT 0, __PHISH_SPEAR_SUBJ_TEAM 0, __RATWARE_SIGNATURE_3_N1 0, __RDNS_WEBMAIL 0, __REFERENCES 0, __SANE_MSGID 0, __STOCK_PHRASE_1 0, __SUBJ_ALPHA_END 0, __SUBJ_ALPHA_NEGATE 0, __SUBJ_REPLY 0, __TO_MALFORMED_2 0, __TO_NO_NAME 0, __URI_IN_BODY 0, __URI_NOT_IMG 0, __URI_NO_WWW 0, __URI_NS , __URI_WITHOUT_PATH 0, __URI_WITH_PATH 0, __YOUTUBE_RCVD 0, __zen.spamhaus.org_ERROR '
X-Spam-Level:
X-PMX-Version: 5.6.1.2065439, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2018.6.7.162116
To: bug-Perl-Tidy [...] rt.cpan.org
X-GM-Message-State: APt69E1JMd+2cGZV9Ers1OWn7gGgEnSF0UbVFK4/6+UYBliiLW8XSnUG Q0If+0A3Od/MM4M1dgY3BJpJ3VSv9n/V6T3JGWXV121H
From: Bob Kleemann <rkleemann [...] gmail.com>
RT-Message-ID: <rt-4.0.18-22188-1528389087-1953.125497-0-0 [...] rt.cpan.org>
Content-Length: 0
content-type: text/plain; charset="utf-8"
X-RT-Original-Encoding: utf-8
Content-Length: 7233
Your original spacing/formatting did not come through, so I reformatted it myself, as I'm guessing that you would have intended. I've also interspersed my comments. Here are some examples of issues that can arise (note: I'm not sure if my original spacing will survive email!) 1. Integers can be a big problem. They may or may not look okay when formatted this way. Consider: my $low = 1; my $delta = 2; my $hi = 101.1; This isn't too bad but it isn't so great either. In this case, as a programmer, I would put an empty line between $delta and $hi, which would then fix the "isn't so great" issue. Consider: my $i = 0; my $conversion_factor = 37458978.21; This doesn't look good at all. This is clearly a case where a blank line between $i and $conversion_factor would make things much more readable. 2. It is very common to have additional operations in lists of numbers, and these may pose a problem. Consider my $conversion_factor = 37458978.21; my $conversion_factor2 = 167.22 * 2; This might be okay. But consider my $conversion_factor = 37458978.21; my $pi2 = 3.14159 * 2; my $pi4 = 4 * 3.14159; my $tol = 0.00000025; This is getting hard to read. This is two separate issues. The $pi2 and $pi4 lines should be structured the same (float times integer or integer times float, but not both), so this is a problem with the programmer. Additionally, those two lines should be separated from the two lines declaring the constants $conversion_factor and $tol. If a programmer were to reformat it the way I'm suggesting, then the alignment is acceptable: my $conversion_factor = 37_458_978.21; my $tol = 0.00_000_025; my $pi2 = 2 * 3.14159; my $pi4 = 4 * 3.14159; 3. Adding the extra spaces to align numbers this way in lists may cause an entire list to be expanded in a very undesirable way. I'm totally agreeing that this might be an issue, which is why you have the #<<< and #>>> anchors. You might also consider a special case of those tags: #<<<no-align-numbers my @perfect_numbers = ( 6, 28, 496, 8_128, 33_550_336, 8_589_869_056, 137_438_691_328, 2_305_843_008_139_952_128, 2_658_455_991_569_831_744_654_692_615_953_842_176 ); #>>> Which would reformat that code: #<<<no-align-numbers my @perfect_numbers = ( 6, 28, 496, 8_128, 33_550_336, 8_589_869_056, 137_438_691_328, 2_305_843_008_139_952_128, 2_658_455_991_569_831_744_654_692_615_953_842_176 ); #>>> Which is less readable, but gets my point across. So, to summarize, a lot of your issues seem like they could be solved with some blank lines, or perhaps a way of turning off the alignment for a particular block of code. Bob On Thu, Jun 7, 2018 at 7:25 AM Steven Hancock via RT < bug-Perl-Tidy@rt.cpan.org> wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=125497 > > > Here are some examples of issues that can arise (note: I'm not sure if my > original spacing will survive email!) > > > 1. Integers can be a big problem. They may or may not look okay when > formatted this way. Consider: > > > my $low = 1; > > my $delta = 2; > > my $hi = 101.1; > > > This isn't too bad but it isn't so great either. > > > Consider: > > > my $i = 0; > > my $conversion_factor = 37458978.21; > > > This doesn't look good at all. > > > 2. It is very common to have additional operations in lists of numbers, > > and these may pose a problem. Consider > > > my $conversion_factor = 37458978.21; > > my $conversion_factor2 = 167.22 * 2; > > > This might be okay. But consider > > > my $conversion_factor = 37458978.21; > > my $pi2 = 3.14159 * 2; > > my $pi4 = 4 * 3.14159; > > my $tol = 0.00000025; > > > This is getting hard to read. > > > > 3. Adding the extra spaces to align numbers this way in lists may cause an > > entire list to be expanded in a very undesirable way. > > > > > On Wed, Jun 6, 2018 at 10:04 AM, Bob Kleemann via RT < > bug-Perl-Tidy@rt.cpan.org> wrote: >
> > Queue: Perl-Tidy > > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=125497 > > > > > How many variations are there? Integers (a series of numbers that does
> not
> > start with 0), decimal (a series of numbers followed by period, followed
> by
> > another series of numbers), floating point (a decimal, followed by an
> 'e',
> > followed by an integer), binary/octal/hex, and I think that's it. All of > > the values should be aligned on the single units or the period, except
> the
> > binary/octal/hex, which should be aligned on the leading 0 (in my
> opinion,
> > I can see discussion on that point). > > > > On Wed, Jun 6, 2018 at 6:58 AM Steven Hancock via RT < > > bug-Perl-Tidy@rt.cpan.org> wrote: > >
> > > <URL: https://rt.cpan.org/Ticket/Display.html?id=125497 > > > > > > > Bob, > > > Thanks for the suggestion. This could also be useful for large tables
> of
> > > values. > > > I did look into it at one time but found that there were so many > > > possible variations that it was hard to code. > > > Steve > > > > > > On Tue, Jun 5, 2018 at 1:40 PM, Bob Kleemann via RT < > > > bug-Perl-Tidy@rt.cpan.org> wrote: > > >
> > > > Tue Jun 05 16:40:42 2018: Request 125497 was acted upon. > > > > Transaction: Ticket created by rkleemann@gmail.com > > > > Queue: Perl-Tidy > > > > Subject: Support aligning numbers correctly > > > > Broken in: (no value) > > > > Severity: (no value) > > > > Owner: Nobody > > > > Requestors: rkleemann@gmail.com > > > > Status: new > > > > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=125497 > > > > > > > > > > > > > It would be nice if numbers were aligned in a sensible way, on the
> > > decimal
> > > > point. Currently, all numbers are left-aligned, which makes sense in
> > the
> > > > simple case, but it would be nice if the following code aligned
> > properly:
> > > > > > > > my $price = 102.99; > > > > my $adjustment = -2.99; > > > > my $tax = 1.0775; > > > > my $final = ( $price + $adjustment ) * $tax; > > > > > > > > > > > > Of course, there is some question about how to align some of the more > > > > elaborate number formats: > > > > > > > > my $avagadro = 6.022140857E23; > > > > my $YYYYddd = 2018.156; > > > > my $pi = 3.14159265; > > > > > > > > my $green = 0x00ff00; > > > > my $rwxrw_rw_ = 0766; > > > > my $escape = 0b00011011; > > > > > > > > > > > > I think I've aligned them in a way that makes sense here, but I could
> > see
> > > > arguments for other alignments. > > > > > > > > Bob > > > > > > > >
> > > > > >
> > > >
> >
content-type: text/html; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
X-RT-Original-Encoding: utf-8
Content-Length: 13464
Download (untitled) / with headers
text/html 13.1k

Message body is not shown because it is too large.

MIME-Version: 1.0
In-Reply-To: <rt-4.0.18-22188-1528389087-1953.125497-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
References: <rt-4.0.18-369-1528293460-290.125497-6-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.18-28567-1528463309-1761.125497-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 745
Download (untitled) / with headers
text/plain 745b
Bob, Those are possible workarounds, but there are some problems. One thing is that many programmers are working on code that they inherited from someone else and probably don’t want to make such detailed changes to keep it from formatting badly. A problem with inserting blank lines to break alignment is that this also breaks the alignment of the equals signs, and one thing I’ve learned is that most people really want the equals aligned. I think that the potential for lists of numbers to look bad is high, and while blocking off selected lists with the #<<< and #>>> symbols is possible, it puts the burden of formatting the list completely on the programmer. For large lists, say 1000 lines long, this isn’t practical. Steve
MIME-Version: 1.0
X-Spam-Status: No, score=-4.194 tagged_above=-99.9 required=10 tests=[AWL=1.139, BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, FROM_OUR_RT=-4, HTML_MESSAGE=0.001, SPF_SOFTFAIL=0.665] autolearn=ham
In-Reply-To: <rt-4.0.18-28567-1528463309-188.125497-6-0 [...] rt.cpan.org>
X-Cpan.org: This message routed through the cpan.org mail forwarding service. Please use PAUSE pause.perl.org to configure your delivery settings.
X-Spam-Flag: NO
X-RT-Interface: API
References: <RT-Ticket-125497 [...] rt.cpan.org> <rt-4.0.18-369-1528293460-290.125497-6-0 [...] rt.cpan.org> <rt-4.0.18-22188-1528389087-1953.125497-6-0 [...] rt.cpan.org> <rt-4.0.18-28567-1528463309-188.125497-6-0 [...] rt.cpan.org>
X-Virus-Scanned: Debian amavisd-new at bestpractical.com
X-Received: by 2002:a37:82c6:: with SMTP id e189-v6mr5755529qkd.322.1528475312586; Fri, 08 Jun 2018 09:28:32 -0700 (PDT)
Message-ID: <CAO6cO59vg1ankmv+-vg3C+Sbq_Ajq_pgGR0BRnC9+cEobVDVcQ [...] mail.gmail.com>
Content-Type: multipart/alternative; boundary="0000000000000e0479056e23e4f9"
X-Spam-Score: -4.194
X-Google-SMTP-Source: ADUXVKKbBeOXgk91gwEgygptozMuutL8/OgPi68D3YZD/z4ocv5UrnGFLLaIcBMdU6nzVmm7/S+/rLsG9CpL2QwIU64=
Authentication-Results: hipster.bestpractical.com (amavisd-new); dkim=pass header.i= [...] gmail.com
Received: from localhost (localhost [127.0.0.1]) by hipster.bestpractical.com (Postfix) with ESMTP id 3ED682403DA for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Fri, 8 Jun 2018 12:28:42 -0400 (EDT)
Received: from hipster.bestpractical.com ([127.0.0.1]) by localhost (hipster.bestpractical.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id a0WppFIHWqNy for <cpan-bug+Perl-Tidy [...] hipster.bestpractical.com>; Fri, 8 Jun 2018 12:28:40 -0400 (EDT)
Received: from xx1.develooper.com (xx1.develooper.com [207.171.7.115]) by hipster.bestpractical.com (Postfix) with ESMTPS id A66432403D5 for <bug-Perl-Tidy [...] rt.cpan.org>; Fri, 8 Jun 2018 12:28:39 -0400 (EDT)
Received: from localhost (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with ESMTP id CDB7011F869 for <bug-Perl-Tidy [...] rt.cpan.org>; Fri, 8 Jun 2018 09:28:38 -0700 (PDT)
Received: from xx1.develooper.com (xx1.develooper.com [127.0.0.1]) by localhost (Postfix) with SMTP id D21E211F848 for <bug-Perl-Tidy [...] rt.cpan.org>; Fri, 8 Jun 2018 09:28:35 -0700 (PDT)
Received: from mail-qk0-f177.google.com (mail-qk0-f177.google.com [209.85.220.177]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by xx1.develooper.com (Postfix) with ESMTPS id 0470B11F65E for <bug-Perl-Tidy [...] rt.cpan.org>; Fri, 8 Jun 2018 09:28:34 -0700 (PDT)
Received: by mail-qk0-f177.google.com with SMTP id a195-v6so9104932qkg.3 for <bug-Perl-Tidy [...] rt.cpan.org>; Fri, 08 Jun 2018 09:28:34 -0700 (PDT)
Delivered-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
Subject: Re: [rt.cpan.org #125497] Support aligning numbers correctly
Return-Path: <rkleemann [...] gmail.com>
Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=EJqM4MX48FozEKdeDqRvzDpkonZGgccZIr8YCDW7SsM=; b=g84yQjPAuY+mBVf1Nv5ruxDmfAb4s5ze+TVYqmX2RuSepDpyorxVhGEboXrVWp0bBL dwKVy9MIIsx7QE5G+KtpNtQN4LxuN1kP4vx0lQ7mb5eQ3zZ93741k6A8GY8H8reUR4kg IvQs3+cPKrG1GA0ew1v38ccA5/oOSiYc/A+xxJrfMVnNI8+LTHpZ4FzP1lm8rmLWHhq/ WKKNVmmgEp3CuiZ9UCF58TfUmdvuoWQQvtffXkQBdiVU8iKKph3Zxz39hfrqfrF7ehGP +PqqQRonZAqTFvZ8l/aFqhIUz3p/n9R6Y+FiV7ZUPIo+S4kXgB94RiW4sJsURozR4XxJ UFZA==
X-Original-To: cpan-bug+Perl-Tidy [...] hipster.bestpractical.com
X-RT-Mail-Extension: perl-tidy
X-Google-Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=EJqM4MX48FozEKdeDqRvzDpkonZGgccZIr8YCDW7SsM=; b=ERjwK2a1avLf/Igd1iqp2kTeznZH8Ip36E5WkPhtYMCuN3T2TvTmSuBro7wD28K7L7 01kAnc7DZFZ3nU6lzKbhXiE3H4U/gLaXcW4qnHh3AklkkchJEKuD+mVcX/qple6NgFOC l/0cpr7duHzqYKCzTbJt4650d7cXZ1J8n46iF0M00quolHT+i5EPoqQdPKweV8eO0wr9 i3a1YX/fEXp/y1CFG2XixX77wd7fT3fL+GUFTNmH+KOGM6rxbqmyM2AB3Jc9vZkWMGiT up2OdWkNWJeNP+p8Uv38Ni4beWwUxGwGE9p6nK3zcqYg3AAYqN6/sE0AvyYN0iFxHYbt K+ZA==
Date: Fri, 8 Jun 2018 09:28:20 -0700
X-PMX-Spam: Gauge=IIIIIIII, Probability=8%, Report=' SUPERLONG_LINE 0.05, BODYTEXTH_SIZE_10000_LESS 0, BODYTEXTP_SIZE_3000_LESS 0, BODY_SIZE_4000_4999 0, BODY_SIZE_5000_LESS 0, BODY_SIZE_7000_LESS 0, DATE_TZ_NA 0, DKIM_SIGNATURE 0, IN_REP_TO 0, LEGITIMATE_SIGNS 0, MSG_THREAD 0, REFERENCES 0, SPF_PASS 0, URI_ENDS_IN_HTML 0, WEBMAIL_SOURCE 0, __ANY_URI 0, __BOUNCE_CHALLENGE_SUBJ 0, __BOUNCE_NDR_SUBJ_EXEMPT 0, __CP_URI_IN_BODY 0, __CT 0, __CTYPE_HAS_BOUNDARY 0, __CTYPE_MULTIPART 0, __CTYPE_MULTIPART_ALT 0, __DQ_NEG_HEUR 0, __DQ_NEG_IP 0, __FORWARDED_MSG 0, __FRAUD_WEBMAIL 0, __FRAUD_WEBMAIL_FROM 0, __FROM_GMAIL 0, __FUR_RDNS_GMAIL 0, __HAS_FROM 0, __HAS_HTML 0, __HAS_MSGID 0, __HELO_GMAIL 0, __HEX28_LC_BOUNDARY 0, __HTML_AHREF_TAG 0, __HTML_TAG_DIV 0, __HTTPS_URI 0, __IN_REP_TO 0, __MIME_HTML 0, __MIME_TEXT_H 0, __MIME_TEXT_H1 0, __MIME_TEXT_H2 0, __MIME_TEXT_P 0, __MIME_TEXT_P1 0, __MIME_TEXT_P2 0, __MIME_VERSION 0, __MULTIPLE_URI_TEXT 0, __PHISH_SPEAR_SUBJ_TEAM 0, __RDNS_WEBMAIL 0, __REFERENCES 0, __SANE_MSGID 0, __SUBJ_ALPHA_END 0, __SUBJ_ALPHA_NEGATE 0, __SUBJ_REPLY 0, __TO_MALFORMED_2 0, __TO_NO_NAME 0, __URI_IN_BODY 0, __URI_NOT_IMG 0, __URI_NO_WWW 0, __URI_NS , __URI_WITHOUT_PATH 0, __URI_WITH_PATH 0, __YOUTUBE_RCVD 0, __zen.spamhaus.org_ERROR '
X-Spam-Level:
X-PMX-Version: 5.6.1.2065439, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2018.6.8.162416
To: bug-Perl-Tidy [...] rt.cpan.org
X-GM-Message-State: APt69E2CtJpFg1TDL8G+d1stHg3RCN9yxgpFzQfHHjYIVdsq7JVwXNJM xVZ5MfrQv+615b0Kig8RduzgS/AAWL/CU2hJZE4YX6z4
From: Bob Kleemann <rkleemann [...] gmail.com>
RT-Message-ID: <rt-4.0.18-18462-1528475323-441.125497-0-0 [...] rt.cpan.org>
Content-Length: 0
content-type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
X-RT-Original-Encoding: utf-8
Content-Length: 1533
Download (untitled) / with headers
text/plain 1.4k
If people are reformatting the code, then I would think they're open to modifications that make the code more readable/understandable. In that case, adding blank lines or no-format sections shouldn't be much of an effort. Still, it's not something that everybody wants, which is why making it a switch that can be turned on/off at will would be sensible. Currently I know that if I am reformatting a section of code with numbers, I'll have to go back and manually realign the numbers. It's annoying, but not the end of the world. However, it is something that the computer should be able to do for me. On Fri, Jun 8, 2018 at 6:09 AM Steve Hancock via RT < bug-Perl-Tidy@rt.cpan.org> wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=125497 > > > Bob, > Those are possible workarounds, but there are some problems. > > One thing is that many programmers are working on code that they inherited > from someone else and probably don’t want to make such detailed changes to > keep it from formatting badly. > > A problem with inserting blank lines to break alignment is that this also > breaks the alignment of the equals signs, and one thing I’ve learned is > that most people really want the equals aligned. > > I think that the potential for lists of numbers to look bad is high, and > while blocking off selected lists with the #<<< and #>>> symbols is > possible, it puts the burden of formatting the list completely on the > programmer. For large lists, say 1000 lines long, this isn’t practical. > > Steve >
content-type: text/html; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
X-RT-Original-Encoding: utf-8
Content-Length: 2380


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.