From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 957 invoked from network); 28 Mar 2021 17:10:34 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 28 Mar 2021 17:10:34 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1616951434; b=sl7tq8Qb3UFYn8I/VX0aQAgrDVkl2SXeb80Q7Olm2lxLCSiVK5n7TcgFFYiF0O0TUCtKjgEnAH tzSfC/nVCC4uERA3IAahGc7CksETpIFmszuzYwan1aBOVWVC/xI6881zWqgrtwuUS9iPXpwKRw UUvyo/+uwnbm2ze+iO5u8mx2AiAgre7pzkHtnBZL4hz9wzBcBx5Qhy6kJZfZ6sBNbl1lDmeN1Y BAIs7INbIplf05FxNKyXaZnkKD65In9hBCd2mv/oXS9opzC+NpTPEQ2fV7xcEj0/EwIAGoKrW0 3PFIfli13t/FUEGYMLJZt+UKwdyNqehXW1+wRlV5L4C4Zg==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-il1-f171.google.com) smtp.remote-ip=209.85.166.171; dkim=pass header.d=gmail.com header.s=20161025 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20200801; t=1616951434; bh=a6Ymt11PGztR99T6OdwSMkoHgxHyl4H1dX7Zc0sHGi8=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Type:Cc:To:Subject:Message-ID:Date:From:References: In-Reply-To:MIME-Version:DKIM-Signature:DKIM-Signature; b=qTCbq1SIapDYroUJrQ905RMo2YPEpjE0hoCbeKRX3RVU8bTIcaIF9QjyJhiuTBFPFDy3nNYMne pp8DMQ9BldCqoFh/YwbV4Yf0eo4bE2xR6MibB5b9Hj0t1AJHfHS3snocvrotEXnXwtcauxL5P7 a8Kixj+C2dUuoGk5QOIAZRp2Y2gzh7u3ZReyB8AX7nOpYP3ye/+0MJMwWmd7s1lqWdFCfiXauF Nu8pLpNw7sVDZi72+UyefHhJ+ZqAeDwS/HxjU9mnuOBJEqH3oqqP6yk2S86FneN7uGhoNuRfV4 H2RTLWWVVYbYqyQh/wxk7Es4BEiOvZWbs4yMM8rKDG57eQ==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20200801; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Type:Cc:To:Subject:Message-ID :Date:From:References:In-Reply-To:MIME-Version:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=QVRoy9Um4TyHDpDlqM6T83sjbDWLWXADpk8gEnXcwEg=; b=TanddA5uqG6PdugwjHKEStPNKK +mBo7650YKDEKGX0eeCNx/wwixzvyhZMFtht27kWBLnezuMzMbJYEJ5hrJ3GIYC/7w0HFJYAE8Mbk RM4wMxnes1j6ufjC88xMWLwQsQsBpDR3MqK/hvrTLB8E/hEdwx1yT9xJiWi7MPRqgl13+OqZ1ilwt 8ZIz9ViXWQvivRD7HRWj1fYYr3np9QvwTfoNrziz7ghhjs66bVOJ5r92zfxKWdga0y1M4JB1iLS15 77acfYZxnTnPd8aVsLYT2kPjaakh5o8x4EYxm28dz5b1PlCfY6uDLErkyXWydo+fkpcEe88NzeKgk aWSLGZVg==; Received: from authenticated user by zero.zsh.org with local id 1lQYvq-000FkP-JT; Sun, 28 Mar 2021 17:10:34 +0000 Authentication-Results: zsh.org; iprev=pass (mail-il1-f171.google.com) smtp.remote-ip=209.85.166.171; dkim=pass header.d=gmail.com header.s=20161025 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none Received: from mail-il1-f171.google.com ([209.85.166.171]:35492) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1lQYvb-000Fb1-Md; Sun, 28 Mar 2021 17:10:20 +0000 Received: by mail-il1-f171.google.com with SMTP id 19so9348133ilj.2 for ; Sun, 28 Mar 2021 10:10:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=QVRoy9Um4TyHDpDlqM6T83sjbDWLWXADpk8gEnXcwEg=; b=QsXsk5caR2BdXHWTHX13ZQwMrcdGPEoWW+j9ivFKUMGXn5EFyEYJbAnlgjUKQjK0QC e/zCHU8NrjEcdy/ry4kDNjNdtMXmXbqAKRvUJ7Lft8SAS3Y4NthGRUcOYCCxdrayaYat wDhqB6/rA4y+xchhX2OoUKjpiAeJYVSR/S7JVG/rjGNkV8FOmLFqbovjEtSLJ9thqbpg V0FKUZBLPnP0SonZywTKiydZfMWKqr+VaJHB/NQ+oKW5RcZ/MUB9HQEEiuIf+xSVawIK o0vj/ooZSXPXat2OfUKMRxIYK8/u4MWvLRxgjBchQPi8MXrn/Iy1RkCia0tQqHiYefLH aycQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=QVRoy9Um4TyHDpDlqM6T83sjbDWLWXADpk8gEnXcwEg=; b=JdsKahBeATjPXi2HZWGvp3wDKWacJtoeEffYaIOuTGVeanCm0xel7srC6Y3j76AMLV BT7Rd/o3lXadvWO/SR832mpWQZNac2p8jf5pnh7cf9JtedhD3O+uRq9pfCESxhG9Rcus gBxF9hgXe3ebup2ctZSyTH1zL5qJ+e4+09oQdFcWScnJCvtssblz7c6yE8HUcCHOplX9 9s79eVkI72HGUk4b+Tt2XAefnBmVubzatqQXFtwgXSx18B8pyCsmmIwdOhhw8l2Sbn47 1e75xeeO9iT+zkM7KC2sFP6tEb7UMQGAPAjIDYIzgPpGEnpkQuevbIITLJXaSeV+ue02 45xQ== X-Gm-Message-State: AOAM532E0tGDSfLCiPzG+OOdBIXWzgQZEVtNRKWznjUcSBVivhNM3KGt 9D+HADARQPYVe0JtH12A1JFGrWUVZQmE4jVAHUs= X-Google-Smtp-Source: ABdhPJyjVtkyMNwqleT0FMysTIRew+3X4xDEZX2XaVNTypTJ4oNWmEAzZnnu47FLdtYxNqEPXxnbbBu9j3h5mbDZz+g= X-Received: by 2002:a05:6e02:20ce:: with SMTP id 14mr18482706ilq.25.1616951418452; Sun, 28 Mar 2021 10:10:18 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a4f:f4d:0:0:0:0:0 with HTTP; Sun, 28 Mar 2021 10:10:17 -0700 (PDT) In-Reply-To: References: From: Mikael Magnusson Date: Sun, 28 Mar 2021 19:10:17 +0200 Message-ID: Subject: Re: Why does _main_complete not try the next completer when $_comp_mesg is non-zero? To: Marlon Richert Cc: Zsh hackers list Content-Type: text/plain; charset="UTF-8" X-Seq: 48288 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: Archived-At: On 3/28/21, Marlon Richert wrote: > The following line in _main_complete > > [[ -n "$_comp_mesg" ]] && break > > has the effect that, whenever _message has been called (with only few > exceptions), the next completer won't be tried, _even when > $compstate[nmatches] is zero._ > > Why? What is the reason for this? > > And is there a convenient way to work around this behavior? I want > _history to be tried when _complete fails, but this behavior often > prevents it. For example, if I try `grep \t`, then I get only the > message `pattern`, whereas I would like to get history words. > > And if there is not an easy workaround, would you accept a patch from > me that changes this? I haven't tested this, but I suspect that if this check were not there, then loops due to approximate matching would print the message multiple times. -- Mikael Magnusson