From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18579 invoked by alias); 13 May 2016 11:25:31 -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: 21559 Received: (qmail 10360 invoked from network); 13 May 2016 11:25:30 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brasslantern-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc; bh=JUBqQJX6kRrTKZyAaUyal8ogi6bi982JTY4tb5iJ2mk=; b=LRU/B4Wo5zVquOkaD868Hw5Le3Qo9K6wfe2fcQ22qtoFAf9BqX4vUWeKdYP2H8a8cw uqytHKDMVOxs+MBFwMSTcAtA4tKLHHTEHnX1ErSH0pDrIIBkX2ljixGYJBg/yR1/Nmku 2hQzBf8YR4k4iy3CQwzi/bv3u3p2fDGfQ+yA9MSi45Dhsw0naeMubSJDaK2xsId2oEgd zkgo/8nSAre3O75mOQivx4kipympR2EeQtxCMEk/Al9cADpjOB8IklSPH8bhMJvgEf1t FbWHd4hK+9iq0jcO6VVjhcnJD+kPcaSB9d4MmVKgQJ4WZcDo3wIrhZok36AzfTuxnJ+1 4+HA== 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; bh=JUBqQJX6kRrTKZyAaUyal8ogi6bi982JTY4tb5iJ2mk=; b=co7xJR3iZJG5pkB7M0hevnl8QdZH/uNUv3ptURDY6bXZ+r4VwoXVqf6vzEApzoWwSW vZsrNRIRY1pyXKe3TmpP018lHos15c3+XSl9B2g1TRf748gB480SrmsHfRhcMXMJXahD f5NeOGjTwaf+e+cfUwl9r5FfUOmwExt09oqIZ645KUMdVEx9dXurrxOSYzoZb672jNIj 7+YeD7Ngw1iyMu7B7tXFUf7sgsZ+1pmYhcz4bfhpnqixOu3g5fDNKbY+EljV+HLmY+vj LBZJ/6I41QC7BYI7F06141tOiPjf9+OJwGdURszfHnkC7Q+aEZGFnhRIX0uKxI1yCcm9 LvRg== X-Gm-Message-State: AOPr4FWENUzmHgUHdG6wekJ7x7mDZLvoqnztjEyErtAssqaAND3LaGlGiXue0zSthZPjA3g8NS2lfVY8+KYXig== MIME-Version: 1.0 X-Received: by 10.112.161.41 with SMTP id xp9mr6310603lbb.133.1463138728498; Fri, 13 May 2016 04:25:28 -0700 (PDT) In-Reply-To: <20160512111628.GG12777@ass.pp.htv.fi> References: <20160512111628.GG12777@ass.pp.htv.fi> Date: Fri, 13 May 2016 04:25:28 -0700 Message-ID: Subject: Re: zparseopts and longopts From: Bart Schaefer To: Zsh Users Cc: Atte Peltomaki Content-Type: text/plain; charset=UTF-8 On Thu, May 12, 2016 at 4:16 AM, Atte Peltomaki wrote: > Executing with imaginary new option: > > % ./test.zsh --gnu argh --gnu-tard rms --gnu-tard-added-even-longer-opt whyohwhy > --gnu argh > --gnu-tard -added-even-longer-opt Well, you've told zparseopts that --gnu-tard is an option that takes a mandatory argument, and you have not told zparseopts that --gnu-tard-add... is an option, and the argument of an option is allowed to appear in the same word as the option itself (so that -a2 is the same as -a 2), so zparseopts believes -add... is the argument of the option you told it about.