Patch 8.0.1839
Problem: Script to check .po file doesn't check for plural header.
Solution: Add a check that the plural header is present when needed.
Files: src/po/check.vim
*** ../vim-8.0.1838/src/po/check.vim 2018-04-30 15:44:21.164299549 +0200
--- src/po/check.vim 2018-05-08 16:05:44.489440582 +0200
***************
*** 157,162 ****
--- 157,179 ----
endif
endif
+ " Check that the plural form is properly initialized
+ 1
+ let plural = search('^msgid_plural ', 'n')
+ if (plural && search('^"Plural-Forms: ', 'n') == 0) || (plural &&
search('^msgstr\[0\] ".\+"', 'n') != plural + 1)
+ if search('^"Plural-Forms: ', 'n') == 0
+ echomsg "Missing Plural header"
+ if error == 0
+ let error = search('\(^"[A-Za-z-_]\+: .*\\n"\n\)\+\zs', 'n') - 1
+ endif
+ elseif error == 0
+ let error = plural
+ endif
+ elseif !plural && search('^"Plural-Forms: ', 'n')
+ " We allow for a stray plural header, msginit adds one.
+ endif
+
+
if error == 0
" If all was OK restore the view.
call winrestview(wsv)
*** ../vim-8.0.1838/src/version.c 2018-05-13 19:06:06.531783844 +0200
--- src/version.c 2018-05-13 22:36:38.194495430 +0200
***************
*** 763,764 ****
--- 763,766 ----
{ /* Add new patch number below this line */
+ /**/
+ 1839,
/**/
--
There is no right or wrong, there is only your personal opinion.
(Bram Moolenaar)
/// 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/d/optout.