bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: `test -R' not working


From: Chet Ramey
Subject: Re: `test -R' not working
Date: Fri, 28 Feb 2014 21:26:54 -0500
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:24.0) Gecko/20100101 Thunderbird/24.3.0

On 2/28/14, 4:50 PM, NBaH wrote:

> Bash Version: 4.3
> Patch Level: 0
> Release Status: release
> 
> Description:
> 
> $ var="foo bar"
> $ declare -n nameref=var
> $ echo "${!nameref} = $nameref"
> var = foo bar
> $ test -R nameref && echo ok || echo ko
> bash: test: -R: unary operator expected
> ko

Thanks for the report.  A line got dropped from a merge back during
development.  I've attached a patch that fixes this and one other problem
with -R.

Chet

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/

Attachment: test-nameref.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]