diff scripts/io/strread.m @ 20191:64f817945783

Use strrep instead of regexprep where possible in m-files for performance. * scripts/gui/private/__fltk_file_filter__.m, scripts/io/strread.m, scripts/plot/util/private/__go_draw_axes__.m, scripts/testfun/private/html_compare_plot_demos.m: Replace instances of regexprep with strrep.
author Rik <rik@octave.org>
date Thu, 14 May 2015 08:55:05 -0700
parents 03b9d17a2d95
children 88efded31037
line wrap: on
line diff
--- a/scripts/io/strread.m	Wed May 06 18:06:19 2015 +0100
+++ b/scripts/io/strread.m	Thu May 14 08:55:05 2015 -0700
@@ -352,7 +352,7 @@
   ## Remove comments in str
   if (comment_flag)
     ## Expand 'eol_char' here, after option processing which may have set value
-    comment_end = regexprep (comment_end, "eol_char", eol_char);
+    comment_end = strrep (comment_end, "eol_char", eol_char);
     cstart = strfind (str, comment_start);
     cstop  = strfind (str, comment_end);
     ## Treat end of string as additional comment stop