From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12426 invoked by alias); 15 Aug 2015 02:09:42 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 36181 Received: (qmail 12932 invoked from network); 15 Aug 2015 02:09:41 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.0 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:message-id:date:in-reply-to:comments :references:to:subject:mime-version:content-type; bh=YOt0whS32mPShlwBOTo0yy97GxonaA2QMIrOBEWpUww=; b=iNc4t3RBZIw25IQQ/1CMQLUuGRWClJnt3s/rMYiUqyrVcnCToauRIqOPZCTtOYLdTd t4FPPGwH4Pnw6Wl4R4cY7WAiTYvJ4J4bHyxDEmJKrEz34MrtZLMGotJHYvu4RrwIiANc UX3nUeHcCou1Ev2lR9RZ4qa4ZJxsvgzHS1/Ln0W31OuurW1YzUC7heZdMOTvQ7NYoSg3 p1yCUjlRSu4H2OseMxoXgfm1W0JvpTTupM5zLk7CtlejxirBFYcJ3Yi+ouZ6yDw+jEIZ riGnzRJvxPSwHFnFVrFK1gFz66O42oH1wlNWz5jilDUCCDOJrS8BBLGhXcdqvnZofVbp i0YA== X-Gm-Message-State: ALoCoQkwHFXsLSppY4itZFYpr/oXGHfvQSzToS9q4J3T5gSlzhkLAxibO3n9kh6atP29LLU6VGTf X-Received: by 10.202.216.135 with SMTP id p129mr38357000oig.90.1439604579540; Fri, 14 Aug 2015 19:09:39 -0700 (PDT) From: Bart Schaefer Message-Id: <150814190936.ZM17069@torch.brasslantern.com> Date: Fri, 14 Aug 2015 19:09:36 -0700 In-Reply-To: <20150815000543.GA2043@zira.vinc17.org> Comments: In reply to Vincent Lefevre "incorrect setopt completion" (Aug 15, 2:05am) References: <20150815000543.GA2043@zira.vinc17.org> X-Mailer: OpenZMail Classic (0.9.2 24April2005) To: zsh-workers@zsh.org Subject: Re: incorrect setopt completion MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii On Aug 15, 2:05am, Vincent Lefevre wrote: } } zira:~> setopt | grep print } printexitvalue } } "setopt nopri[TAB]" and "unsetopt pri[TAB]" don't give any completion. } However "setopt pri[TAB]" has printexitvalue among its completions. } This should be the opposite! Hm. _main_complete is saving the state of the options as early as it can, but XTRACE, PRINTEXITVALUE, LOCALOPTIONS, and LOCALLOOPS are all subject to being saved/restored during the execution of shell functions, which of course means the entirety of compsys. There's no way to fix this from shell script code. The state of the options will have to be stashed somewhere at the C code level before completion functions are entered, if we want this to work.