At 00:35 -0700 1999/05/05, Mark P Jones wrote:
>| The first is that despite that the option is
>|     -p"%s> "
>| optionsToStr() prints it as
>|     -p"> "
>
>optionsToStr() does not exhibit this behavior on my machine, and I'm
>guessing that the problem you have is in the way you are using it.
>I'll bet you have code that looks something like:
>
>   printf(optionsToStr());
>
>Try the following instead:
>
>   printf("%s",optionsToStr());

This was the bug. It is this C-programming that is causing it. Have not
thought about switching to C++?

>| Then the second is that despite the option is
>|     -E""
>| when printing out with the command :s, it prints out as
>| Editor setting  : -E

>| Please come up with a quick fix.
>
>My pleasure!  Try -E"%s"

This is not a big deal: So far it appears to be just a bug in the printing
display when using the :s command. The function optionsToStr() prints is
correctly as -E"" when the empty string is used.

I do not yet know if initialize() can distinguish correctly between -E
(internally becoming the NULL pointer) and -E"" (internally becoming a
malloc() allocated empty string string "").

But that is all that is needed, for my purposes.

>| Try -E"%s"
>
>A side note to you on the specifics of how this is implemented; I don't
>think this setting will work for cases when an editor is invoked with no
>known file.  (That doesn't happen much, but it is possible.)  I have
>two thoughts on this.  The first is that inserting a space might do the
>trick (i.e., -E" %s" ... in fact that might be necessary to get the trick
>working in the first place; without a Mac, I can't test it).  The second
>is that perhaps we should modify the way the editor command is constructed
>so that it stops looking for an editor name when it sees a % character.
>There's already a special case in the Mac code for this, and it shouldn't
>be too big a change.

This does not have anything at all to do with it: I wrote a special version
of system() for MacOS that launches a file to its creator. Thus the editor
is unnecessary.

  Hans Aberg
                  * Email: Hans Aberg <mailto:[EMAIL PROTECTED]>
                  * Home Page: <http://www.matematik.su.se/~haberg/>
                  * AMS member listing: <http://www.ams.org/cml/>

Reply via email to