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

With 'spellang=en,he' and 'complete+=kspell', completion often hangs

Expand Messages
  • Ron Aaron
    I don t know if the problem is having two dictionaries or specifically with the Hebrew dictionary, but if I have an English text and press Ctrl-N to complete a
    Message 1 of 7 , Jun 13, 2013
    • 0 Attachment
      I don't know if the problem is having two dictionaries or specifically with the Hebrew dictionary, but if I have an English text and press Ctrl-N to complete a word, I get an initial display of matches and then Vim freezes up with a "searching..." message on the status line.

      If I change "spellang=en" everything is fine.

      OK, when I changed to "spelllang=he", and edit a Hebrew only text, I get the same problem. So there is something "not right" with how that dictionary is being searched.

      --
      --
      You received this message from the "vim_dev" maillist.
      Do not top-post! Type your reply below the text you are replying to.
      For more information, visit http://www.vim.org/maillist.php

      ---
      You received this message because you are subscribed to the Google Groups "vim_dev" group.
      To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
      For more options, visit https://groups.google.com/groups/opt_out.
    • Bram Moolenaar
      ... Can you use a debugger to find out where Vim is hanging? -- Some of the well known MS-Windows errors: ESLEEP Operator fell asleep ENOERR No error yet
      Message 2 of 7 , Jun 14, 2013
      • 0 Attachment
        Ron Aaron wrote:

        > I don't know if the problem is having two dictionaries or specifically
        > with the Hebrew dictionary, but if I have an English text and press
        > Ctrl-N to complete a word, I get an initial display of matches and
        > then Vim freezes up with a "searching..." message on the status line.
        >
        > If I change "spellang=en" everything is fine.
        >
        > OK, when I changed to "spelllang=he", and edit a Hebrew only text, I
        > get the same problem. So there is something "not right" with how that
        > dictionary is being searched.

        Can you use a debugger to find out where Vim is hanging?

        --
        Some of the well known MS-Windows errors:
        ESLEEP Operator fell asleep
        ENOERR No error yet
        EDOLLAR OS too expensive
        EWINDOWS MS-Windows loaded, system in danger

        /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
        /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
        \\\ an exciting new programming language -- http://www.Zimbu.org ///
        \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

        --
        --
        You received this message from the "vim_dev" maillist.
        Do not top-post! Type your reply below the text you are replying to.
        For more information, visit http://www.vim.org/maillist.php

        ---
        You received this message because you are subscribed to the Google Groups "vim_dev" group.
        To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
        For more options, visit https://groups.google.com/groups/opt_out.
      • Ron Aaron
        0x0811c8db in utf_ptr2char (p=0xbfffef24 ילוציי ) at mbyte.c:1704 1704 return ((p[0] & 0x1f)
        Message 3 of 7 , Jun 14, 2013
        • 0 Attachment
          0x0811c8db in utf_ptr2char (p=0xbfffef24 "ילוציי") at mbyte.c:1704
          1704 return ((p[0] & 0x1f) << 6) + (p[1] & 0x3f);
          (gdb) bt
          #0 0x0811c8db in utf_ptr2char (p=0xbfffef24 "ילוציי") at mbyte.c:1704
          #1 0x0811ccb8 in utf_composinglike (p1=0xbfffef22 "אילוציי", p2=0xbfffef24 "ילוציי") at mbyte.c:1869
          #2 0x0811d147 in utfc_ptr2len (p=0xbfffef22 "אילוציי") at mbyte.c:2085
          #3 0x08112290 in vim_strchr (string=0xbfffef22 "אילוציי", c=1493) at misc2.c:1893
          #4 0x0816224c in cstrchr (s=0xbfffef22 "אילוציי", c=1493) at regexp.c:7142
          #5 0x0816b97d in skip_to_start (c=1493, colp=0xbfffdbc0) at regexp_nfa.c:4835
          #6 0x0816e90b in nfa_regexec_both (line=0xbfffef22 "אילוציי", startcol=0) at regexp_nfa.c:6362
          #7 0x0816ecba in nfa_regexec (rmp=0xbfffdc48, line=0xbfffef22 "אילוציי", col=0) at regexp_nfa.c:6556
          #8 0x0816ef04 in vim_regexec (rmp=0xbfffdc48, line=0xbfffef22 "אילוציי", col=0) at regexp.c:8038
          #9 0x081907e1 in valid_word_prefix (totprefcnt=25, arridx=216, flags=83886112, word=0xbfffef22 "אילוציי", slang=0x83a66e0, cond_req=0)
          at spell.c:1958
          #10 0x081adbe0 in dump_prefixes (slang=0x83a66e0, word=0xbfffef22 "אילוציי", pat=0x87c152a "compl", dir=0xbffff064, dumpflags=0,
          flags=83886112, startlnum=0) at spell.c:15950
          #11 0x081ad3c6 in spell_dump_compl (pat=0x87c152a "compl", ic=0, dir=0xbffff064, dumpflags_arg=0) at spell.c:15761
          #12 0x08067c2a in ins_compl_dictionaries (dict_start=0x87badf5 "spell", pat=0x87c1528 "\\<compl", flags=1, thesaurus=0) at edit.c:3120
          #13 0x08069ade in ins_compl_get_exp (ini=0x8351e58 <compl_startpos>) at edit.c:4308
          #14 0x0806a6f3 in ins_compl_next (allow_get_expansion=1, count=1, insert_match=1) at edit.c:4715
          #15 0x0806ba6d in ins_complete (c=16) at edit.c:5386
          #16 0x080653e5 in edit (cmdchar=111, startln=1, count=1) at edit.c:1410
          #17 0x0812d666 in invoke_edit (cap=0xbffff3ac, repl=0, cmd=111, startln=1) at normal.c:9228
          #18 0x0812c7f5 in n_opencmd (cap=0xbffff3ac) at normal.c:8540
          #19 0x0812df77 in nv_open (cap=0xbffff3ac) at normal.c:9574
          #20 0x08120aba in normal_cmd (oap=0xbffff430, toplevel=1) at normal.c:1200
          #21 0x081fb57c in main_loop (cmdwin=0, noexmode=0) at main.c:1329
          #22 0x081faf26 in main (argc=3, argv=0xbffff644) at main.c:1020


          Some time later:

          0x0819076d in valid_word_prefix (totprefcnt=25, arridx=216, flags=83886112, word=0xbfffef22 "במאיתה", slang=0x83a66e0, cond_req=0)
          at spell.c:1940
          1940 pidx = slang->sl_pidxs[arridx + prefcnt];
          (gdb) bt
          #0 0x0819076d in valid_word_prefix (totprefcnt=25, arridx=216, flags=83886112, word=0xbfffef22 "במאיתה", slang=0x83a66e0, cond_req=0)
          at spell.c:1940
          #1 0x081adbe0 in dump_prefixes (slang=0x83a66e0, word=0xbfffef22 "במאיתה", pat=0x87c152a "compl", dir=0xbffff064, dumpflags=0,
          flags=83886112, startlnum=0) at spell.c:15950
          #2 0x081ad3c6 in spell_dump_compl (pat=0x87c152a "compl", ic=0, dir=0xbffff064, dumpflags_arg=0) at spell.c:15761
          #3 0x08067c2a in ins_compl_dictionaries (dict_start=0x87badf5 "spell", pat=0x87c1528 "\\<compl", flags=1, thesaurus=0) at edit.c:3120
          #4 0x08069ade in ins_compl_get_exp (ini=0x8351e58 <compl_startpos>) at edit.c:4308
          #5 0x0806a6f3 in ins_compl_next (allow_get_expansion=1, count=1, insert_match=1) at edit.c:4715
          #6 0x0806ba6d in ins_complete (c=16) at edit.c:5386
          #7 0x080653e5 in edit (cmdchar=111, startln=1, count=1) at edit.c:1410
          #8 0x0812d666 in invoke_edit (cap=0xbffff3ac, repl=0, cmd=111, startln=1) at normal.c:9228
          #9 0x0812c7f5 in n_opencmd (cap=0xbffff3ac) at normal.c:8540
          #10 0x0812df77 in nv_open (cap=0xbffff3ac) at normal.c:9574
          #11 0x08120aba in normal_cmd (oap=0xbffff430, toplevel=1) at normal.c:1200
          #12 0x081fb57c in main_loop (cmdwin=0, noexmode=0) at main.c:1329
          #13 0x081faf26 in main (argc=3, argv=0xbffff644) at main.c:1020

          --
          --
          You received this message from the "vim_dev" maillist.
          Do not top-post! Type your reply below the text you are replying to.
          For more information, visit http://www.vim.org/maillist.php

          ---
          You received this message because you are subscribed to the Google Groups "vim_dev" group.
          To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
          For more options, visit https://groups.google.com/groups/opt_out.
        • Bram Moolenaar
          ... OK, so it doesn t really hang, it s just terribly slow. The Hebrew spell file isn t made for this. Recommentation: don t use it. -- hundred-and-one
          Message 4 of 7 , Jun 14, 2013
          • 0 Attachment
            Ron Aaron wrote:

            > 0x0811c8db in utf_ptr2char (p=0xbfffef24 "ילוציי") at mbyte.c:1704
            > 1704 return ((p[0] & 0x1f) << 6) + (p[1] & 0x3f);
            > (gdb) bt
            > #0 0x0811c8db in utf_ptr2char (p=0xbfffef24 "ילוציי") at mbyte.c:1704
            > #1 0x0811ccb8 in utf_composinglike (p1=0xbfffef22 "אילוציי", p2=0xbfffef24 "ילוציי") at mbyte.c:1869
            > #2 0x0811d147 in utfc_ptr2len (p=0xbfffef22 "אילוציי") at mbyte.c:2085
            > #3 0x08112290 in vim_strchr (string=0xbfffef22 "אילוציי", c=1493) at misc2.c:1893
            > #4 0x0816224c in cstrchr (s=0xbfffef22 "אילוציי", c=1493) at regexp.c:7142
            > #5 0x0816b97d in skip_to_start (c=1493, colp=0xbfffdbc0) at regexp_nfa.c:4835
            > #6 0x0816e90b in nfa_regexec_both (line=0xbfffef22 "אילוציי", startcol=0) at regexp_nfa.c:6362
            > #7 0x0816ecba in nfa_regexec (rmp=0xbfffdc48, line=0xbfffef22 "אילוציי", col=0) at regexp_nfa.c:6556
            > #8 0x0816ef04 in vim_regexec (rmp=0xbfffdc48, line=0xbfffef22 "אילוציי", col=0) at regexp.c:8038
            > #9 0x081907e1 in valid_word_prefix (totprefcnt=25, arridx=216, flags=83886112, word=0xbfffef22 "אילוציי", slang=0x83a66e0, cond_req=0)
            > at spell.c:1958
            > #10 0x081adbe0 in dump_prefixes (slang=0x83a66e0, word=0xbfffef22 "אילוציי", pat=0x87c152a "compl", dir=0xbffff064, dumpflags=0,
            > flags=83886112, startlnum=0) at spell.c:15950
            > #11 0x081ad3c6 in spell_dump_compl (pat=0x87c152a "compl", ic=0, dir=0xbffff064, dumpflags_arg=0) at spell.c:15761
            > #12 0x08067c2a in ins_compl_dictionaries (dict_start=0x87badf5 "spell", pat=0x87c1528 "\\<compl", flags=1, thesaurus=0) at edit.c:3120
            > #13 0x08069ade in ins_compl_get_exp (ini=0x8351e58 <compl_startpos>) at edit.c:4308
            > #14 0x0806a6f3 in ins_compl_next (allow_get_expansion=1, count=1, insert_match=1) at edit.c:4715
            > #15 0x0806ba6d in ins_complete (c=16) at edit.c:5386
            > #16 0x080653e5 in edit (cmdchar=111, startln=1, count=1) at edit.c:1410
            > #17 0x0812d666 in invoke_edit (cap=0xbffff3ac, repl=0, cmd=111, startln=1) at normal.c:9228
            > #18 0x0812c7f5 in n_opencmd (cap=0xbffff3ac) at normal.c:8540
            > #19 0x0812df77 in nv_open (cap=0xbffff3ac) at normal.c:9574
            > #20 0x08120aba in normal_cmd (oap=0xbffff430, toplevel=1) at normal.c:1200
            > #21 0x081fb57c in main_loop (cmdwin=0, noexmode=0) at main.c:1329
            > #22 0x081faf26 in main (argc=3, argv=0xbffff644) at main.c:1020
            >
            >
            > Some time later:
            >
            > 0x0819076d in valid_word_prefix (totprefcnt=25, arridx=216, flags=83886112, word=0xbfffef22 "במאיתה", slang=0x83a66e0, cond_req=0)
            > at spell.c:1940
            > 1940 pidx = slang->sl_pidxs[arridx + prefcnt];
            > (gdb) bt
            > #0 0x0819076d in valid_word_prefix (totprefcnt=25, arridx=216, flags=83886112, word=0xbfffef22 "במאיתה", slang=0x83a66e0, cond_req=0)
            > at spell.c:1940
            > #1 0x081adbe0 in dump_prefixes (slang=0x83a66e0, word=0xbfffef22 "במאיתה", pat=0x87c152a "compl", dir=0xbffff064, dumpflags=0,
            > flags=83886112, startlnum=0) at spell.c:15950
            > #2 0x081ad3c6 in spell_dump_compl (pat=0x87c152a "compl", ic=0, dir=0xbffff064, dumpflags_arg=0) at spell.c:15761
            > #3 0x08067c2a in ins_compl_dictionaries (dict_start=0x87badf5 "spell", pat=0x87c1528 "\\<compl", flags=1, thesaurus=0) at edit.c:3120
            > #4 0x08069ade in ins_compl_get_exp (ini=0x8351e58 <compl_startpos>) at edit.c:4308
            > #5 0x0806a6f3 in ins_compl_next (allow_get_expansion=1, count=1, insert_match=1) at edit.c:4715
            > #6 0x0806ba6d in ins_complete (c=16) at edit.c:5386
            > #7 0x080653e5 in edit (cmdchar=111, startln=1, count=1) at edit.c:1410
            > #8 0x0812d666 in invoke_edit (cap=0xbffff3ac, repl=0, cmd=111, startln=1) at normal.c:9228
            > #9 0x0812c7f5 in n_opencmd (cap=0xbffff3ac) at normal.c:8540
            > #10 0x0812df77 in nv_open (cap=0xbffff3ac) at normal.c:9574
            > #11 0x08120aba in normal_cmd (oap=0xbffff430, toplevel=1) at normal.c:1200
            > #12 0x081fb57c in main_loop (cmdwin=0, noexmode=0) at main.c:1329
            > #13 0x081faf26 in main (argc=3, argv=0xbffff644) at main.c:1020

            OK, so it doesn't really hang, it's just terribly slow.
            The Hebrew spell file isn't made for this.
            Recommentation: don't use it.

            --
            hundred-and-one symptoms of being an internet addict:
            204. You're being audited because you mailed your tax return to the IRC.

            /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
            /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
            \\\ an exciting new programming language -- http://www.Zimbu.org ///
            \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

            --
            --
            You received this message from the "vim_dev" maillist.
            Do not top-post! Type your reply below the text you are replying to.
            For more information, visit http://www.vim.org/maillist.php

            ---
            You received this message because you are subscribed to the Google Groups "vim_dev" group.
            To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
            For more options, visit https://groups.google.com/groups/opt_out.
          • Ron Aaron
            C mon, Bram, is that the best you can suggest? Don t use that spell file ? What is it that makes it unusably slow, and how can I work around it? Is the
            Message 5 of 7 , Jun 15, 2013
            • 0 Attachment
              C'mon, Bram, is that the best you can suggest? "Don't use that spell file"?

              What is it that makes it unusably slow, and how can I work around it? Is the problem the affix stuff?

              --
              --
              You received this message from the "vim_dev" maillist.
              Do not top-post! Type your reply below the text you are replying to.
              For more information, visit http://www.vim.org/maillist.php

              ---
              You received this message because you are subscribed to the Google Groups "vim_dev" group.
              To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
              For more options, visit https://groups.google.com/groups/opt_out.
            • Bram Moolenaar
              ... The completion works by generating a dump of all valid words. This spell file has way too many ways to make valid words. That s OK when checking a word
              Message 6 of 7 , Jun 15, 2013
              • 0 Attachment
                Ron Aaron wrote:

                > C'mon, Bram, is that the best you can suggest? "Don't use that spell file"?
                >
                > What is it that makes it unusably slow, and how can I work around it?
                > Is the problem the affix stuff?

                The completion works by generating a dump of all valid words. This
                spell file has way too many ways to make valid words. That's OK when
                checking a word for being valid, but the list is just too long to use
                for completion.

                The help for :spelldump:

                :spelld[ump] Open a new window and fill it with all currently valid
                words. Compound words are not included.
                Note: For some languages the result may be enormous,
                causing Vim to run out of memory.

                --
                hundred-and-one symptoms of being an internet addict:
                219. Your spouse has his or her lawyer deliver the divorce papers...
                via e-mail.

                /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
                /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
                \\\ an exciting new programming language -- http://www.Zimbu.org ///
                \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

                --
                --
                You received this message from the "vim_dev" maillist.
                Do not top-post! Type your reply below the text you are replying to.
                For more information, visit http://www.vim.org/maillist.php

                ---
                You received this message because you are subscribed to the Google Groups "vim_dev" group.
                To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
                For more options, visit https://groups.google.com/groups/opt_out.
              • Ron Aaron
                ... Hmmm. Isn t there a way to generate a list of only words beginning with a certain prefix? After all, complete generally means you have some text
                Message 7 of 7 , Jun 15, 2013
                • 0 Attachment
                  On Saturday, June 15, 2013 10:54:37 PM UTC+3, Bram Moolenaar wrote:
                  > The completion works by generating a dump of all valid words. This

                  Hmmm. Isn't there a way to generate a list of only words beginning with a certain prefix? After all, "complete" generally means you have some text written already and you want just to complete likely matches.

                  --
                  --
                  You received this message from the "vim_dev" maillist.
                  Do not top-post! Type your reply below the text you are replying to.
                  For more information, visit http://www.vim.org/maillist.php

                  ---
                  You received this message because you are subscribed to the Google Groups "vim_dev" group.
                  To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
                  For more options, visit https://groups.google.com/groups/opt_out.
                Your message has been successfully submitted and would be delivered to recipients shortly.