On 8/26/06, Martin Bähr <[EMAIL PROTECTED]> wrote:
> On Sat, Aug 26, 2006 at 01:14:29AM +0200, Axel Liljencrantz wrote:
> > > > I hadn't thought of it that way. Unfortunatly, there is no way around
> > > > this problem that I can see. So one has to weigh the benefit against
> > > > the drawbacks. Hard call.
> > > what are the drawbacks?
> > When I said drawbacks I was talking about the script vs. commandline
> > differences you where describing.
>
> ah, i thought you were talking about the drawback of keeping script and
> interactive mode compatible.

No, as you said, that hardly has any drawbacks in itself. Quite the opposite.

>
> > I've been thinking about ways to fix the assignment-for-single-command
> > problem without introducing script vs. commandline differences. One
> > way would be to introduce a new switch to set, -s / --single-command:
> >
> > set -s CC icc; make
> >
> > would mean set the value of CC to icc, but only for the make command. May 
> > be ok.
>
> what about something like:
> make (set CC icc)
>
> (just random brainstorming)

Heh, that is kind of cool. Yes, making each command behave as a block
for it's command substitutions would possibly work. But weird, though.
But since no one else on the list seems interested on doing this, and
simply using env works ok most of the time, I am pretty close to
admitting defeat and letting go of the entire idea.

>
> > > my apologies if that is a dumb question, obviously i am not familiar
> > > with fish internals, but my naive view of this would be: what is the
> > > problem with keeping the state of blocks in interactive mode?
> > > don't you have to do the same thing while interpreting a script?
> > There is no problem. What you are suggesting is how fish has always
> > worked. My suggestion was to change this
>
> well, actually i was changing the topic here (sorry)
> i meant to ask: what are the problems with supporting multiline blocks
> in interactive mode without any multiline editing?

Ok, then I understand your question better. I hope.

It would be possible and a bit easier then the full multiline editor
thing, but not by much.

eval(), the main code evaluation function needs to get a complete
block of code as it's input, so the interactive editor would need some
kind of lookaside buffer to save incomplete lines to. The
non-interactive mode gets around this issue by feeding the entire file
to the eval function.

>
> that would solve the pasting problem which currently does exist.

It would, but like I said, it's not significantly easier to implement.

>
> greetings, martin.
> --
> cooperative communication with sTeam      -     caudium, pike, roxen and unix
> offering: programming, training and administration   -  anywhere in the world
> --
> pike programmer   travelling and working in europe             open-steam.org
> unix system-      bahai.or.at                        iaeste.(tuwien.ac|or).at
> administrator     (caudium|gotpike).org                          is.schon.org
> Martin Bähr       http://www.iaeste.or.at/~mbaehr/
>


-- 
Axel

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Fish-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fish-users

Reply via email to