From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6802 invoked by alias); 21 Nov 2014 21:38:21 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 19414 Received: (qmail 21902 invoked from network); 21 Nov 2014 21:38:17 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,HTML_MESSAGE, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=2+1FcFK5CT2SBR6cuFCtO5rib6fTBH5gsBQvdU6Nh3Q=; b=SO0DMsYaHW78eag0pSRRiJxdEo+ceJFaQwdziFd2CBteCsIPtq/NCTA1tL2UeOqcFb r3MURvJ2XdeKmwpzVORsgA94JRVSsLmZKALPyiBx0GQdNPVUU2oYV0GEzdvzbycBATiy EN5obqSk2Y+arcMOt6uB9zXqtvYmBctO+owszBQ3mu69zuvQ2w3SExyGE3w6o8kgrvjK tSP9R6FFGskGcK01ImRmFnC9LgvGaYdtD8finMh2bWctmXb+Gepnb9NDFPCFz/jqC+lj Bvvn3Ols2p5nVLYWbiFP/J1KKfBjbTUVeaFn1fuKQY8Nmr4WKV3UPB4dhh2QVjMmzJho Fsrw== X-Gm-Message-State: ALoCoQl80BjPPMFR2Cnl3xTMYabxvhsZIQOb3UM9eULGHIf4B7x+x2tXlm3+ChDoxJMjhezHiA5S MIME-Version: 1.0 X-Received: by 10.180.91.49 with SMTP id cb17mr573102wib.30.1416605395086; Fri, 21 Nov 2014 13:29:55 -0800 (PST) In-Reply-To: <546F9F41.8040608@eastlink.ca> References: <546F9F41.8040608@eastlink.ca> Date: Fri, 21 Nov 2014 13:29:54 -0800 Message-ID: Subject: Re: syntactic question From: Bart Schaefer To: Ray Andrews Cc: Zsh Users Content-Type: multipart/alternative; boundary=f46d043c7b2a5c8686050865252f --f46d043c7b2a5c8686050865252f Content-Type: text/plain; charset=UTF-8 On Nov 21, 2014 12:25 PM, "Ray Andrews" wrote: > > I've always thought that all parsing systems work from the 'inside out' > which is to say that (as with math) you 'do' the deepest parenthesis > first, and then work outward. Quotes aren't parens, there is no left and right so you can't nest them the way you are thinking of. With only a small number of exceptions, quoting in shells works left to right - once a quote is open, you obey only the rules of that type of quote until it closes again. Backslashes happen to have special meaning both inside and outside of quotes, but the details depend on which type of quote is active. > In the same spirit, I'm expecting > the substitution to do what it does following it's own rules and > nevermind any quotations or anything else 'further out'. Substitution occurs if there are no quotes or inside double quotes, but not inside single quotes. The rules are different when in double quotes, and documented. --f46d043c7b2a5c8686050865252f--