zsh-workers
 help / color / mirror / code / Atom feed
From: Vincent Lefevre <vincent@vinc17.net>
To: zsh-workers@zsh.org
Subject: Re: completion on brace + 4 characters doesn't work
Date: Fri, 29 Apr 2011 02:59:09 +0200	[thread overview]
Message-ID: <20110429005909.GB21935@prunille.vinc17.org> (raw)
In-Reply-To: <20110429003149.GA21935@prunille.vinc17.org>

On 2011-04-29 02:31:49 +0200, Vincent Lefevre wrote:
> On 2011-04-29 00:27:54 +0200, Vincent Lefevre wrote:
> > I've looked at Debian's patches for the zsh package, but I don't
> > see anything related to the problem here.
> 
> I have recompiled the official zsh 4.3.11 under Debian, and have the
> same problem with it.

I've done a strace in both cases.

With "echo ./{abc[TAB]", I get:

[...]
16059 stat("/home/vlefevre/zsh-test/share/zsh/site-functions.zwc", 0x7fff7a4b17f0) = -1 ENOENT (No such file or directory)
16059 stat("/home/vlefevre/zsh-test/share/zsh/site-functions/_have_glob_qual.zwc", 0x7fff7a4b1760) = -1 ENOENT (No such file or directory)
16059 stat("/home/vlefevre/zsh-test/share/zsh/site-functions/_have_glob_qual", 0x7fff7a4b16d0) = -1 ENOENT (No such file or directory)
16059 access("/home/vlefevre/zsh-test/share/zsh/site-functions/_have_glob_qual", R_OK) = -1 ENOENT (No such file or directory)
16059 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions.zwc", 0x7fff7a4b17f0) = -1 ENOENT (No such file or directory)
16059 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_have_glob_qual.zwc", 0x7fff7a4b1760) = -1 ENOENT (No such file or directory)
16059 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_have_glob_qual", {st_mode=S_IFREG|0644, st_size=858, ...}) = 0
16059 access("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_have_glob_qual", R_OK) = 0
16059 open("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_have_glob_qual", O_RDONLY|O_NOCTTY) = 3
16059 lseek(3, 0, SEEK_END)             = 858
16059 lseek(3, 0, SEEK_SET)             = 0
16059 read(3, "#autoload\n\n# Test if $1 has glob"..., 858) = 858
16059 close(3)                          = 0
[...]
16059 open("/dev/null", O_WRONLY|O_CREAT|O_NOCTTY|O_TRUNC, 0666) = 3
16059 fcntl(2, F_DUPFD, 10)             = 12
16059 close(2)                          = 0
16059 dup2(3, 2)                        = 2
16059 close(3)                          = 0
16059 open("./", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
16059 getdents(3, /* 3 entries */, 32768) = 80
16059 getdents(3, /* 0 entries */, 32768) = 0
16059 close(3)                          = 0
16059 dup2(12, 2)                       = 2
16059 close(12)                         = 0
[...]
16059 stat("/home/vlefevre/zsh-test/share/zsh/site-functions.zwc", 0x7fff7a4b0240) = -1 ENOENT (No such file or directory)
16059 stat("/home/vlefevre/zsh-test/share/zsh/site-functions/_list_files.zwc", 0x7fff7a4b01b0) = -1 ENOENT (No such file or directory)
16059 stat("/home/vlefevre/zsh-test/share/zsh/site-functions/_list_files", 0x7fff7a4b0120) = -1 ENOENT (No such file or directory)
16059 access("/home/vlefevre/zsh-test/share/zsh/site-functions/_list_files", R_OK) = -1 ENOENT (No such file or directory)
16059 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions.zwc", 0x7fff7a4b0240) = -1 ENOENT (No such file or directory)
16059 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_list_files.zwc", 0x7fff7a4b01b0) = -1 ENOENT (No such file or directory)
16059 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_list_files", {st_mode=S_IFREG|0644, st_size=1420, ...}) = 0
16059 access("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_list_files", R_OK) = 0
16059 open("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_list_files", O_RDONLY|O_NOCTTY) = 3
16059 lseek(3, 0, SEEK_END)             = 1420
16059 lseek(3, 0, SEEK_SET)             = 0
16059 read(3, "#autoload\n\n# Helper function for"..., 1420) = 1420
16059 close(3)                          = 0
[...]
16059 lstat("./abcdef", {st_mode=S_IFREG|0644, st_size=0, ...}) = 0
16059 stat("./abcdef", {st_mode=S_IFREG|0644, st_size=0, ...}) = 0
[...]

With "echo ./{abcd[TAB]", I get:

[...]
16063 stat("/home/vlefevre/zsh-test/share/zsh/site-functions.zwc", 0x7fffd1930340) = -1 ENOENT (No such file or directory)
16063 stat("/home/vlefevre/zsh-test/share/zsh/site-functions/_have_glob_qual.zwc", 0x7fffd19302b0) = -1 ENOENT (No such file or directory)
16063 stat("/home/vlefevre/zsh-test/share/zsh/site-functions/_have_glob_qual", 0x7fffd1930220) = -1 ENOENT (No such file or directory)
16063 access("/home/vlefevre/zsh-test/share/zsh/site-functions/_have_glob_qual", R_OK) = -1 ENOENT (No such file or directory)
16063 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions.zwc", 0x7fffd1930340) = -1 ENOENT (No such file or directory)
16063 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_have_glob_qual.zwc", 0x7fffd19302b0) = -1 ENOENT (No such file or directory)
16063 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_have_glob_qual", {st_mode=S_IFREG|0644, st_size=858, ...}) = 0
16063 access("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_have_glob_qual", R_OK) = 0
16063 open("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_have_glob_qual", O_RDONLY|O_NOCTTY) = 3
16063 lseek(3, 0, SEEK_END)             = 858
16063 lseek(3, 0, SEEK_SET)             = 0
16063 read(3, "#autoload\n\n# Test if $1 has glob"..., 858) = 858
16063 close(3)                          = 0
[...]
16063 open("/dev/null", O_WRONLY|O_CREAT|O_NOCTTY|O_TRUNC, 0666) = 3
16063 fcntl(2, F_DUPFD, 10)             = 12
16063 close(2)                          = 0
16063 dup2(3, 2)                        = 2
16063 close(3)                          = 0
16063 open("./", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
16063 getdents(3, /* 3 entries */, 32768) = 80
16063 getdents(3, /* 0 entries */, 32768) = 0
16063 close(3)                          = 0
16063 dup2(12, 2)                       = 2
16063 close(12)                         = 0
[...]
16063 access("./acdd", F_OK)            = -1 ENOENT (No such file or directory)
[...]
16063 stat("/home/vlefevre/zsh-test/share/zsh/site-functions.zwc", 0x7fffd193ab60) = -1 ENOENT (No such file or directory)
16063 stat("/home/vlefevre/zsh-test/share/zsh/site-functions/_ignored.zwc", 0x7fffd193aad0) = -1 ENOENT (No such file or directory)
16063 stat("/home/vlefevre/zsh-test/share/zsh/site-functions/_ignored", 0x7fffd193aa40) = -1 ENOENT (No such file or directory)
16063 access("/home/vlefevre/zsh-test/share/zsh/site-functions/_ignored", R_OK) = -1 ENOENT (No such file or directory)
16063 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions.zwc", 0x7fffd193ab60) = -1 ENOENT (No such file or directory)
16063 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_ignored.zwc", 0x7fffd193aad0) = -1 ENOENT (No such file or directory)
16063 stat("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_ignored", {st_mode=S_IFREG|0644, st_size=1647, ...}) = 0
16063 access("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_ignored", R_OK) = 0
16063 open("/home/vlefevre/zsh-test/share/zsh/4.3.11/functions/_ignored", O_RDONLY|O_NOCTTY) = 3
16063 lseek(3, 0, SEEK_END)             = 1647
16063 lseek(3, 0, SEEK_SET)             = 0
16063 read(3, "#autoload\n\n# Use ignored matches"..., 1647) = 1647
16063 close(3)                          = 0
[...]

The question is why this access("./acdd", F_OK) in the latter case?

-- 
Vincent Lefèvre <vincent@vinc17.net> - Web: <http://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <http://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / Arénaire project (LIP, ENS-Lyon)


  reply	other threads:[~2011-04-29  0:59 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-28 11:11 Vincent Lefevre
2011-04-28 15:12 ` Bart Schaefer
2011-04-28 22:27   ` Vincent Lefevre
2011-04-29  0:31     ` Vincent Lefevre
2011-04-29  0:59       ` Vincent Lefevre [this message]
2011-04-29  1:34         ` Vincent Lefevre
2011-04-29  3:56           ` Bart Schaefer
2011-04-29  8:44             ` Vincent Lefevre
2011-04-29 11:15               ` Vincent Lefevre
2011-05-04  9:33                 ` Vincent Lefevre
2011-04-29 14:20               ` Bart Schaefer
2011-05-02  8:08                 ` Vincent Lefevre
2011-05-02  8:34                   ` Vincent Lefevre
2011-05-02 11:54                     ` Peter Stephenson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110429005909.GB21935@prunille.vinc17.org \
    --to=vincent@vinc17.net \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).