The latest version of vim that ships with macOS Tahoe seems to have issues with syntax highlighting for potentially long strings in Python. To reproduce:
vim data.pysyntax onx = ' (must be single quote, double quote has no issue)This results in the following error msg:
E363: Pattern uses more memory than 'maxmempattern'
Vim is unable to recover from this even after the string is closed. I must reopen the file or rerun syntax on.
I have no ~/.vimrc or ~/.vim to influence reproducibility.
I would expect vim to have some kind of fallback behavior when it can't find the end of a string, and gracefully recover once the string is complete.
9.1
OS: macOS Tahoe 26.1
Terminal: Terminal 2.15 (465)
$TERM: xterm-256color
Shell: fish 4.0.0
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
Cannot reproduce, please always try to reproduce using vim --clean. I also wonder what this means: "vim that ships with macOS Tahoe" and you did not share the whole :version output.
So please try latest version of master branch using vim --clean. And if this is fixed, complain to Apple about this.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
Apologies for the missing information, perhaps these suggestions could be added to the GitHub issue template?
I am able to reproduce this issue with vim --clean.
Full :version output:
VIM - Vi IMproved 9.1 (2024 Jan 02, compiled Oct 11 2025 01:19:19)
macOS version - arm64
Included patches: 1-1752
Compiled by ro...@apple.com
Normal version without GUI. Features included (+) or not (-):
+acl +cmdline_hist +ex_extra +jumplist +mouse_dec -perl -socketserver +terminfo +vreplace
-arabic +cmdline_info +extra_search -keymap -mouse_gpm +persistent_undo -sodium +termresponse -wayland
+autocmd +comments -farsi +lambda -mouse_jsbterm +popupwin -sound +textobjects -wayland_clipboard
+autochdir +conceal +file_in_path -langmap +mouse_netterm +postscript +spell +textprop +wildignore
-autoservername +cryptv +find_in_path +libcall +mouse_sgr +printer +startuptime +timers +wildmenu
-balloon_eval +cscope +float +linebreak -mouse_sysmouse -profile +statusline +title +windows
-balloon_eval_term +cursorbind +folding +lispindent +mouse_urxvt -python -sun_workshop -toolbar +writebackup
-browse +cursorshape -footer +listcmds +mouse_xterm -python3 +syntax +user_commands -X11
++builtin_terms +dialog_con +fork() +localmap +multi_byte +quickfix -tabpanel -vartabs -xattr
+byte_offset +diff -gettext -lua +multi_lang +reltime +tag_binary +vertsplit -xfontset
+channel +digraphs -hangul_input +menu -mzscheme -rightleft -tag_old_static +vim9script -xim
+cindent -dnd +iconv +mksession +netbeans_intg -ruby -tag_any_white +viminfo -xpm
-clientserver -ebcdic +insert_expand +modify_fname +num64 +scrollbind -tcl +virtualedit -xsmp
+clipboard -emacs_tags +ipv6 +mouse +packages +signs +termguicolors +visual -xterm_clipboard
+cmdline_compl +eval +job -mouseshape +path_extra +smartindent +terminal +visualextra -xterm_save
system vimrc file: "$VIM/vimrc"
user vimrc file: "$HOME/.vimrc"
2nd user vimrc file: "~/.vim/vimrc"
3rd user vimrc file: "~/.config/vim/vimrc"
user exrc file: "$HOME/.exrc"
defaults file: "$VIMRUNTIME/defaults.vim"
fall-back for $VIM: "/usr/share/vim"
Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H -DMACOS_X_UNIX -g -O2 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: gcc -L/usr/local/lib -o vim -lm -lncurses -liconv -framework Cocoa
I am not able to reproduce the issue with vim's master branch:
VIM - Vi IMproved 9.1 (2024 Jan 02, compiled Jan 4 2026 19:23:02)
macOS version - arm64
Included patches: 1-2050
Compiled by Adam@Vesuvius
Normal version without GUI. Features included (+) or not (-):
+acl +comments +float +localmap +netbeans_intg +smartindent +textobjects +wildmenu
-arabic +conceal +folding -lua +num64 +socketserver +textprop +windows
+autocmd +cryptv -footer +menu +packages -sodium +timers +writebackup
+autochdir -cscope +fork() +mksession +path_extra -sound +title -X11
-autoservername +cursorbind -gettext +modify_fname -perl +spell -toolbar -xattr
-balloon_eval +cursorshape -hangul_input +mouse +persistent_undo +startuptime +user_commands -xfontset
-balloon_eval_term +dialog_con +iconv -mouseshape +popupwin +statusline -vartabs -xim
-browse +diff +insert_expand +mouse_dec +postscript -sun_workshop +vertsplit -xpm
++builtin_terms +digraphs +ipv6 -mouse_gpm +printer +syntax +vim9script -xsmp
+byte_offset -dnd +job -mouse_jsbterm -profile -tabpanel +viminfo -xterm_clipboard
+channel -ebcdic +jumplist +mouse_netterm -python +tag_binary +virtualedit -xterm_save
+cindent -emacs_tags -keymap +mouse_sgr -python3 -tag_old_static +visual
+clientserver +eval +lambda -mouse_sysmouse +quickfix -tag_any_white +visualextra
+clipboard +ex_extra -langmap +mouse_urxvt +reltime -tcl +vreplace
+clipboard_provider +extra_search +libcall +mouse_xterm -rightleft +termguicolors -wayland
+cmdline_compl -farsi +linebreak +multi_byte -ruby -terminal -wayland_clipboard
+cmdline_hist +file_in_path +lispindent +multi_lang +scrollbind +terminfo -wayland_focus_steal
+cmdline_info +find_in_path +listcmds -mzscheme +signs +termresponse +wildignore
system vimrc file: "$VIM/vimrc"
user vimrc file: "$HOME/.vimrc"
2nd user vimrc file: "~/.vim/vimrc"
3rd user vimrc file: "~/.config/vim/vimrc"
user exrc file: "$HOME/.exrc"
defaults file: "$VIMRUNTIME/defaults.vim"
fall-back for $VIM: "/Users/Adam/spack/opt/spack/darwin-m2/vim-master-b2gfcadm6qjg64jbozmmlouinu7yfikh/share/vim"
Compilation: /Users/Adam/spack/opt/spack/darwin-m2/compiler-wrapper-1.0-e6qqck2oywzs7oyslnaqpflwk72b2fwd/libexec/spack/clang/clang -c -I. -Iproto -DHAVE_CONFIG_H -DMACOS_X -DMACOS_X_DARW
IN -g -O2 -D_REENTRANT -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: /Users/Adam/spack/opt/spack/darwin-m2/compiler-wrapper-1.0-e6qqck2oywzs7oyslnaqpflwk72b2fwd/libexec/spack/clang/clang -o vim -lm -ltinfow -liconv -framework AppKit
I will try to open a bug report with Apple and use my source build for now.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
Closed #19079 as completed.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()