delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2019/02/05/19:25:01

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:message-id:date:from:mime-version:to:subject
:references:in-reply-to:content-type:content-transfer-encoding;
q=dns; s=default; b=hAxag0P6m34q+i3S+3/YbAZntRdPqmnE6TBOXfj7SEm
3LsiY0jHjAryQi9GSxopmDhbnXdgV5fftnOR+t9H8DbvaHaQyCDn1ARVLTNvgHwb
CKr+Jj9lvwij7Kg8Yqo+RpN8wbGfXyIi4J1YYp9mRZielK/CNgGtR4+jrLnHLDVQ
=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:message-id:date:from:mime-version:to:subject
:references:in-reply-to:content-type:content-transfer-encoding;
s=default; bh=diqTAWfyE6So2v827oKoJEgzlpE=; b=Cf4flLPeG41ZyRboY
QXDif03CbBWwIEzfoGqZosHeKwO7I0sDs3Ha33+zKDVOlnK13Nd/2p6cxSHGG7eA
Hl1a6VZX/8z0wqptAb55/yum7gQsQ2jMWK85FIJwfL0iBx0K0RzFAn24Uqu1QWmE
5QASyAb7/oP/eabMZ7K+w4Uuww=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Spam-SWARE-Status: No, score=-6.9 required=5.0 tests=BAYES_00,GIT_PATCH_2 autolearn=ham version=3.3.2 spammy=Wayne, davison, Davison, H*F:U*cygwin
X-HELO: Ishtar.sc.tlinx.org
Message-ID: <5C5A28EB.7090804@tlinx.org>
Date: Tue, 05 Feb 2019 16:23:07 -0800
From: L A Walsh <cygwin AT tlinx DOT org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: perl -- classic?
References: <5C58BD83 DOT 5060806 AT tlinx DOT org> <CAHSx_SuD++hhsvKkAsrNcexnPtzV-qts_ApMP7V9b74K+Rzkvw AT mail DOT gmail DOT com>
In-Reply-To: <CAHSx_SuD++hhsvKkAsrNcexnPtzV-qts_ApMP7V9b74K+Rzkvw@mail.gmail.com>
X-IsSubscribed: yes

On 2/4/2019 4:18 PM, Wayne Davison wrote:
> On Mon, Feb 4, 2019 at 2:33 PM L A Walsh wrote:
>   
>> Things like
>> Term::Size::chars no longer works as it says chars isn't exported.
>> but it is 'EXPORT_OK', and it used to work.
>>     
>
> Remember that EXPORT_OK means that you can ask for it to be exported,
> but it's not by default.  I just tried out CPAN 2.22 with perl 5.26.3
> and ran a CPAN "install Term::Size" and the result worked fine:
>
> perl -we 'use Term::Size "chars"; print join("\n",  chars), "\n";'
> perl -we 'use Term::Size; print join("\n",  Term::Size::chars), "\n";'
>
> I haven't seen any issues in the various CPAN modules that I added to my setup.
>   
---
    Yes...it worked for me up till the latest perl.  I was surprised.

The man page documents usage as:

       "Term::Size::chars" returns the size in units of characters, whereas
       "Term::Size::pixels" uses units of pixels.

       In a scalar context, both functions return the first element of the
       list, that is, the terminal width.

       The functions may be imported.

-----



--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019