Christian Brabandt wrote: > On Mi, 15 Jan 2014, Aidan Marlin wrote: > > Vim devs, > > > > I have discovered a bug which affects at least 7.4.135 and (likely) > > 7.3.547. Example file is available at > > https://mega.co.nz/#!ndVjXZTY!aMX_9ll-0ce861tQwNZBaFveb_kONCJxvAT2GZOvzlc > > (1.2MB in size) which will crash vim when attempting the following regex: > > > > :%s/\n//g > > > > The file contains 20 000 lines, each line containing 60 characters. > > > > Join (:%j) works fine and fast in these versions of vim, while the above > > regex seems to consume excessive amounts of memory, and results in vim > > crash. > > How about to alias :s/\n// to the join function (see attached patch).
OK, but with a slightly different pattern it would still be a problem. Did you look at the cause of the problem? -- If Apple would build a car... ... it would be powered by the sun, be reliable, five times as fast and twice as easy to drive; but would only run on five percent of the roads. /// Bram Moolenaar -- [email protected] -- 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 [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
