Loading ...
Sorry, an error occurred while loading the content.

Can't put text with P, but p still works

Expand Messages
  • Dr Bean
    map P reveals no mappings. This is the vim on Fedora Core 3. ... VIM - Vi IMproved 6.3 (2004 June 7, compiled Oct 19 2004 17:17:57) 適用済パッチ: 1-21,
    Message 1 of 5 , Jul 13, 2006
    • 0 Attachment
      map P reveals no mappings.

      This is the vim on Fedora Core 3.

      :version
      VIM - Vi IMproved 6.3 (2004 June 7, compiled Oct 19 2004 17:17:57)
      適用済パッチ: 1-21, 23-24, 26, 28-30
      Modified by <bugzilla@...>
      Compiled by <bugzilla@...>
      Huge 版 without GUI. 機能の一覧 有効(+)/無効(-)
      +arabic +autocmd -balloon_eval -browse ++builtin_terms +byte_offset +cindent
      -clientserver -clipboard +cmdline_compl +cmdline_hist +cmdline_info +comments
      +cryptv +cscope +dialog_con +diff +digraphs -dnd -ebcdic +emacs_tags +eval
      +ex_extra +extra_search +farsi +file_in_path +find_in_path +folding -footer
      +fork() +gettext -hangul_input +iconv +insert_expand +jumplist +keymap +langmap
      +libcall +linebreak +lispindent +listcmds +localmap +menu +mksession
      +modify_fname +mouse -mouseshape +mouse_dec +mouse_gpm -mouse_jsbterm
      +mouse_netterm +mouse_xterm +multi_byte +multi_lang -netbeans_intg -osfiletype
      +path_extra +perl +postscript +printer +python +quickfix +rightleft -ruby
      +scrollbind +signs +smartindent -sniff +statusline -sun_workshop +syntax
      +tag_binary +tag_old_static -tag_any_white -tcl +terminfo +termresponse
      +textobjects +title -toolbar +user_commands +vertsplit +virtualedit +visual
      +visualextra +viminfo +vreplace +wildignore +wildmenu +windows +writebackup
      -X11 -xfontset -xim -xsmp -xterm_clipboard -xterm_save
      システム vimrc: "/etc/vimrc"
      ユーザ vimrc: "$HOME/.vimrc"
      ユーザ exrc: "$HOME/.exrc"
      省略時の $VIM: "/usr/share/vim"
      コンパイル: i386-redhat-linux-gcc -c -I. -Iproto -DHAVE_CONFIG_H -O2 -g -pipe -m32 -march=i386 -mtune=pentium4 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBUGGING -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -I/usr/lib/perl5/5.8.5/i386-linux-thread-multi/CORE -I/usr/include/python2.3 -pthread
      リンク: i386-redhat-linux-gcc -Wl,-E -Wl,-rpath,/usr/lib/perl5/5.8.5/i386-linux-thread-multi/CORE -L/usr/local/lib -o vim -lncurses -lselinux -lacl -lgpm -Wl,-E -Wl,-rpath,/usr/lib/perl5/5.8.5/i386-linux-thread-multi/CORE -L/usr/local/lib /usr/lib/perl5/5.8.5/i386-linux-thread-multi/auto/DynaLoader/DynaLoader.a -L/usr/lib/perl5/5.8.5/i386-linux-thread-multi/CORE -lperl -lutil -lc -L/usr/lib/python2.3/config -lpython2.3 -lutil -lm -Xlinker -export-dynamic

      --
      Dr Bean Management is doing things right;
      Leadership is doing the right things.
      --Peter Drucker
    • Benji Fisher
      ... Please try starting vim with $ vim -u NONE and see whether the problem persists. If it does, please give a very explicit example of how p works but P
      Message 2 of 5 , Jul 14, 2006
      • 0 Attachment
        On Fri, Jul 14, 2006 at 10:02:48AM +0800, Dr Bean wrote:
        > map P reveals no mappings.
        >
        > This is the vim on Fedora Core 3.
        >
        > :version
        > VIM - Vi IMproved 6.3 (2004 June 7, compiled Oct 19 2004 17:17:57)
        > 適用済パッチ: 1-21, 23-24, 26, 28-30
        > Modified by <bugzilla@...>
        > Compiled by <bugzilla@...>
        > Huge 版 without GUI. 機能の一覧 有効(+)/無効(-)

        Please try starting vim with

        $ vim -u NONE

        and see whether the problem persists. If it does, please give a very
        explicit example of how "p" works but "P" does not.

        Since your version of vim was modified and compiled by redhat, I am
        tempted to blame them for any problems, but it is too early to make that
        decision now.

        HTH --Benji Fisher
      • Dr Bean
        ... It appears to be a sessions problem. I only have it when I run vim -S Sessions.vim. With vim -u NONE -U NONE the problem with P in a session goes away. BUt
        Message 3 of 5 , Jul 14, 2006
        • 0 Attachment
          On Fri, 14 Jul 2006, Benji Fisher wrote:

          > On Fri, Jul 14, 2006 at 10:02:48AM +0800, Dr Bean wrote:
          > > map P reveals no mappings.

          > > This is the vim on Fedora Core 3.

          > > :version
          > > VIM - Vi IMproved 6.3 (2004 June 7, compiled Oct 19 2004 17:17:57)
          > > 適用済パッチ: 1-21, 23-24, 26, 28-30
          > > Modified by <bugzilla@...>
          > > Compiled by <bugzilla@...>
          > > Huge 版 without GUI. 機能の一覧 有効(+)/無効(-)

          > Please try starting vim with

          > $ vim -u NONE

          > and see whether the problem persists. If it does, please give a very
          > explicit example of how "p" works but "P" does not.

          It appears to be a sessions problem. I only have it when I run
          vim -S Sessions.vim.

          With vim -u NONE -U NONE the problem with P in a session goes away. BUt I get
          vi-undo with u.

          This suggests session monkeying with cpoptions is to blame.

          And I have in my vimrc:

          map \P :set paste!<CR>: se paste?<CR>

          And although P doesn't do anything except in ex: mode, I see it is toggling
          the paste option.

          I wonder if this is cpo flag B.

          --
          Dr Bean Doing things right is doing the right thing.
          Doing things wrong is education.
          --Dr Bean
        • Yakov Lerner
          ... It does. I don t know it whis is intended behaviour or not, but your problem goes away if you do set cpo+=B Can you verify that your &cpo has no B ?
          Message 4 of 5 , Jul 14, 2006
          • 0 Attachment
            On 7/14/06, Dr Bean <lang@...> wrote:
            > On Fri, 14 Jul 2006, Benji Fisher wrote:
            >
            > > On Fri, Jul 14, 2006 at 10:02:48AM +0800, Dr Bean wrote:
            > > > map P reveals no mappings.
            >
            > > > This is the vim on Fedora Core 3.
            >
            > > > :version
            > > > VIM - Vi IMproved 6.3 (2004 June 7, compiled Oct 19 2004 17:17:57)
            > > > 適用済パッチ: 1-21, 23-24, 26, 28-30
            > > > Modified by <bugzilla@...>
            > > > Compiled by <bugzilla@...>
            > > > Huge 版 without GUI. 機能の一覧 有効(+)/無効(-)
            >
            > > Please try starting vim with
            >
            > > $ vim -u NONE
            >
            > > and see whether the problem persists. If it does, please give a very
            > > explicit example of how "p" works but "P" does not.
            >
            > It appears to be a sessions problem. I only have it when I run
            > vim -S Sessions.vim.
            >
            > With vim -u NONE -U NONE the problem with P in a session goes away. BUt I get
            > vi-undo with u.
            >
            > This suggests session monkeying with cpoptions is to blame.
            >
            > And I have in my vimrc:
            >
            > map \P :set paste!<CR>: se paste?<CR>
            >
            > And although P doesn't do anything except in ex: mode, I see it is toggling
            > the paste option.
            >
            > I wonder if this is cpo flag B.

            It does. I don't know it whis is intended behaviour or not,
            but your problem goes away if you do
            set cpo+=B
            Can you verify that your &cpo has no 'B' ? Mine 'cpo' does.

            The small experiment shows this:
            1. :set cpo+=B
            :nmap \P :echo "abc"<cr>
            \P shows abc on commandline
            P does not

            2. :set cpo+=B
            :nmap \P :echo "abc"<cr>
            P shows abc on commandline !!!
            \P shows abc on commandline

            I don't know whether this is intended or bug.
            From the text that descibes 'B' flag of 'cpo', it
            does not follow that without B backslash shall
            ignored in rhs of mapping.

            Yakov
          • Dr Bean
            ... This is actually the system vimrc. I don t have a ~/.vimrc. ... I have cpoptions=aABeFsM In a session, cpoptions=aABeFs, the vim default apparently. B is
            Message 5 of 5 , Jul 14, 2006
            • 0 Attachment
              On Fri, 14 Jul 2006, Yakov Lerner wrote:

              > On 7/14/06, Dr Bean <lang@...> wrote:
              > >On Fri, 14 Jul 2006, Benji Fisher wrote:

              > >> On Fri, Jul 14, 2006 at 10:02:48AM +0800, Dr Bean wrote:
              > >> > map P reveals no mappings.

              > >> > This is the vim on Fedora Core 3.

              > >> > :version
              > >> > VIM - Vi IMproved 6.3 (2004 June 7, compiled Oct 19 2004 17:17:57)
              > >> > 適用済パッチ: 1-21, 23-24, 26, 28-30
              > >> > Modified by <bugzilla@...>
              > >> > Compiled by <bugzilla@...>
              > >> > Huge 版 without GUI. 機能の一覧 有効(+)/無効(-)

              > >> Please try starting vim with

              > >> $ vim -u NONE

              > >> and see whether the problem persists. If it does, please give a very
              > >> explicit example of how "p" works but "P" does not.

              > >It appears to be a sessions problem. I only have it when I run
              > >vim -S Sessions.vim.

              > >With vim -u NONE -U NONE the problem with P in a session goes away. BUt I
              > >get
              > >vi-undo with u.

              > >This suggests session monkeying with cpoptions is to blame.

              > >And I have in my vimrc:

              This is actually the system vimrc. I don't have a ~/.vimrc.

              > >map \P :set paste!<CR>: se paste?<CR>

              > >And although P doesn't do anything except in ex: mode, I see it is
              > >toggling
              > >the paste option.

              > >I wonder if this is cpo flag B.

              > It does. I don't know it whis is intended behaviour or not,
              > but your problem goes away if you do
              > set cpo+=B
              > Can you verify that your &cpo has no 'B' ? Mine 'cpo' does.

              I have cpoptions=aABeFsM
              In a session, cpoptions=aABeFs, the vim default apparently.

              B is present both times, so it looks like the explantaion is more
              complicated.

              With -u NONE -U NONE,
              cpoptions=aAbBcCdDeEfFgijJkKlLmMnoOprRsStuvwWxy$!%*<

              > The small experiment shows this:
              > 1. :set cpo+=B
              > :nmap \P :echo "abc"<cr>
              > \P shows abc on commandline
              > P does not

              Yes, I get the same outside a session.

              > 2. :set cpo+=B
              I think you mean :set cpo-=B
              > :nmap \P :echo "abc"<cr>
              > P shows abc on commandline !!!
              > \P shows abc on commandline

              Yes, I get the same outside a session.

              > I don't know whether this is intended or bug.
              > >From the text that descibes 'B' flag of 'cpo', it
              > does not follow that without B backslash shall
              > ignored in rhs of mapping.

              Yes, it's a bit difficult to reconcile the two.

              A number of plugins change cpo. I seem to have broken Luc
              Hermitte's bracketing macros with my own changes.

              On another machine I am getting:

              Error detected while processing function <SNR>15_LoadBrackets..Trigger_Function..Trigger_DoSwitch..Brackets:
              line 70:
              E10: \ should be followed by /, ? or &

              The help says this is often caused by command-line continutation
              being disabled by the C flag.

              Perhaps all these cpo anomalies are a symptom of
              my careless hacking.

              --
              Dr Bean All teaching is teaching
              under difficult circumstances.
              --Dr Bean
            Your message has been successfully submitted and would be delivered to recipients shortly.