bug-bash
[Top][All Lists]
Advanced

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

Re: How come math/arithmetic cannot work by set -x


From: Lawrence Velázquez
Subject: Re: How come math/arithmetic cannot work by set -x
Date: Fri, 12 Aug 2022 20:23:53 -0400
User-agent: Cyrus-JMAP/3.7.0-alpha0-841-g7899e99a45-fm-20220811.002-g7899e99a

On Fri, Aug 12, 2022, at 7:40 PM, Dennis Williamson wrote:
> It works for me. What are you expecting?
>
> It would help if you show what you're doing, the result you're getting and
> what you expect instead.

I'm guessing that instead of, for example

        % bash -xc 'a="(x=1)" b="2*3"; ((a+b))'
        + a='(x=1)'
        + b='2*3'
        + (( a+b ))

they want something like

        % bash -xc 'a="(x=1)" b="2*3"; ((a+b))'
        + a='(x=1)'
        + b='2*3'
        + (( a+b ))
        + (( (x=1)+2*3 ))
        + (( 1+6 ))
        + (( 7 ))

or whatever.  Who knows.

-- 
vq



reply via email to

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