To: vim_dev@googlegroups.com Subject: Patch 9.0.1455 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 9.0.1455 Problem: C++ 20 modules are not recognized. Solution: Add patterns to recognize C++ 20 modules as "cpp". (Ben Jackson, closes #12261) Files: runtime/filetype.vim, src/testdir/test_filetype.vim *** ../vim-9.0.1454/runtime/filetype.vim 2023-03-28 21:28:32.694343665 +0100 --- runtime/filetype.vim 2023-04-15 18:13:24.484063409 +0100 *************** *** 338,343 **** --- 338,347 ---- au BufNewFile,BufRead *.C,*.H setf cpp endif + " C++ 20 modules (clang) + " https://clang.llvm.org/docs/StandardCPlusPlusModules.html#file-name-requirement + au BufNewFile,BufRead *.cppm,*.ccm,*.cxxm,*.c++m setf cpp + " .h files can be C, Ch C++, ObjC or ObjC++. " Set c_syntax_for_h if you want C, ch_syntax_for_h if you want Ch. ObjC is " detected automatically. *** ../vim-9.0.1454/src/testdir/test_filetype.vim 2023-04-02 20:29:33.741597887 +0100 --- src/testdir/test_filetype.vim 2023-04-15 18:13:24.484063409 +0100 *************** *** 127,133 **** \ 'context': ['tex/context/any/file.tex', 'file.mkii', 'file.mkiv', 'file.mkvi', 'file.mkxl', 'file.mklx'], \ 'cook': ['file.cook'], \ 'cpon': ['file.cpon'], ! \ 'cpp': ['file.cxx', 'file.c++', 'file.hh', 'file.hxx', 'file.hpp', 'file.ipp', 'file.moc', 'file.tcc', 'file.inl', 'file.tlh'], \ 'cqlang': ['file.cql'], \ 'crm': ['file.crm'], \ 'crontab': ['crontab', 'crontab.file', '/etc/cron.d/file', 'any/etc/cron.d/file'], --- 127,133 ---- \ 'context': ['tex/context/any/file.tex', 'file.mkii', 'file.mkiv', 'file.mkvi', 'file.mkxl', 'file.mklx'], \ 'cook': ['file.cook'], \ 'cpon': ['file.cpon'], ! \ 'cpp': ['file.cxx', 'file.c++', 'file.hh', 'file.hxx', 'file.hpp', 'file.ipp', 'file.moc', 'file.tcc', 'file.inl', 'file.tlh', 'file.cppm', 'file.ccm', 'file.cxxm', 'file.c++m'], \ 'cqlang': ['file.cql'], \ 'crm': ['file.crm'], \ 'crontab': ['crontab', 'crontab.file', '/etc/cron.d/file', 'any/etc/cron.d/file'], *** ../vim-9.0.1454/src/version.c 2023-04-15 13:17:22.879094522 +0100 --- src/version.c 2023-04-15 18:16:14.127980140 +0100 *************** *** 697,698 **** --- 697,700 ---- { /* Add new patch number below this line */ + /**/ + 1455, /**/ -- To the optimist, the glass is half full. To the pessimist, the glass is half empty. To the engineer, the glass is twice as big as it needs to be. /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// \\\ \\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///