/* Lasciate ogni speranza. *
* This function is a nightmare. It works, but I'm sure that nobody really *
* understands why. The problem is: to make it cleaner we would need *
* changes in the lexer code (and then in the parser, and then...). */
It doesn’t surprise me in the least bit, considering how complex everything seems to be in zsh.
Years ago, I was trying to understand how the completion system works. I never understood.
Even the user-facing shit you need to put in your .zshrc in order to enable completion in the first place does not look like it’s made for a human to read. Not to mention that you need to enable it in the first place.
Configuring zsh was such a mess for me, for years. I don’t know why I used it for so long. Glad I gave fish a shot.
I once had the misfortune of having to read zsh source code…
In unrelated news I no longer use zsh.
I will look at the source code later, but your comment is very ominous
Now I’m curious, tell us more. What did you see?!
/* Lasciate ogni speranza. * * This function is a nightmare. It works, but I'm sure that nobody really * * understands why. The problem is: to make it cleaner we would need * * changes in the lexer code (and then in the parser, and then...). */source
there are more if you keep reading… (also, spoiler alert, this function doesn’t work, that was why i was looking at it.)
It doesn’t surprise me in the least bit, considering how complex everything seems to be in zsh.
Years ago, I was trying to understand how the completion system works. I never understood.
Even the user-facing shit you need to put in your .zshrc in order to enable completion in the first place does not look like it’s made for a human to read. Not to mention that you need to enable it in the first place.
Configuring zsh was such a mess for me, for years. I don’t know why I used it for so long. Glad I gave fish a shot.
I mean, with a file named
zle_tricky.c…it’s all just regex, isn’t it