zsh-users
 help / color / mirror / code / Atom feed
* error with zed
@ 2015-10-01  0:22 Ray Andrews
  2015-10-01  1:52 ` Bart Schaefer
  0 siblings, 1 reply; 4+ messages in thread
From: Ray Andrews @ 2015-10-01  0:22 UTC (permalink / raw)
  To: Zsh Users

With this dummy function:

    function z ()
    {
       select selection in ${path[@]}
    }


I source it and run it:

$ z
     1) /aWorking/Bin      3) /usr/sbin          5) /sbin
     2) /usr/local/bin     4) /usr/bin           6) /bin

       MAKE A SELECTION ... 1

...
But trying to edit the function with zed:

     $ zed -f z

    z () {
             select selection in ${path[@]}

             done
    }

... and on exiting:

     (eval):4: parse error near `done'

So far I've only found one of my functions that I can't edit
with zed, and it boils down to the single line above.  God
knows where the 'done' is coming from.  The full length function
that throws this error runs just fine but zed won't eat it.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: error with zed
  2015-10-01  0:22 error with zed Ray Andrews
@ 2015-10-01  1:52 ` Bart Schaefer
  2015-10-01  2:57   ` Ray Andrews
  0 siblings, 1 reply; 4+ messages in thread
From: Bart Schaefer @ 2015-10-01  1:52 UTC (permalink / raw)
  To: Zsh Users

On Sep 30,  5:22pm, Ray Andrews wrote:
}
}      $ zed -f z
} 
}     z () {
}              select selection in ${path[@]}
} 
}              done
}     }

Apparently "select" is not a very frequently-used construct.

diff --git a/Src/text.c b/Src/text.c
index 7e65f43..9421d70 100644
--- a/Src/text.c
+++ b/Src/text.c
@@ -632,8 +632,10 @@ gettext2(Estate state)
 		    taddstr(" in ");
 		    taddlist(state, *state->pc++);
 		}
-		tindent++;
 		taddnl(0);
+		taddstr("do");
+		taddnl(0);
+		tindent++;
 		tpush(code, 1);
 	    } else {
 		dec_tindent();

-- 
Barton E. Schaefer


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: error with zed
  2015-10-01  1:52 ` Bart Schaefer
@ 2015-10-01  2:57   ` Ray Andrews
  2015-10-01  3:48     ` Ray Andrews
  0 siblings, 1 reply; 4+ messages in thread
From: Ray Andrews @ 2015-10-01  2:57 UTC (permalink / raw)
  To: zsh-users

On 09/30/2015 06:52 PM, Bart Schaefer wrote:

I haven't done a git pull for a long time.  Tried it and:

     $ echo $ZSH_PATCHLEVEL
     zsh-5.0.7-319-g4edcacb

That's not current is it? I'd like to check that patch you just made.




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: error with zed
  2015-10-01  2:57   ` Ray Andrews
@ 2015-10-01  3:48     ` Ray Andrews
  0 siblings, 0 replies; 4+ messages in thread
From: Ray Andrews @ 2015-10-01  3:48 UTC (permalink / raw)
  To: zsh-users

On 09/30/2015 07:57 PM, Ray Andrews wrote:
> On 09/30/2015 06:52 PM, Bart Schaefer wrote:
>
> I haven't done a git pull for a long time.  Tried it and:
>
>     $ echo $ZSH_PATCHLEVEL
>     zsh-5.0.7-319-g4edcacb
>
> That's not current is it? I'd like to check that patch you just made.
>

Had to erase everything and 'git clone ...' from scratch:


zsh-5.1.1-67-gbc2e73b

... much better. Bug fixed.


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-10-01  3:48 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-01  0:22 error with zed Ray Andrews
2015-10-01  1:52 ` Bart Schaefer
2015-10-01  2:57   ` Ray Andrews
2015-10-01  3:48     ` Ray Andrews

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).