docs: fix vim.filetype.add by avoiding quotes (#19433)

* Problem

Quotes are special in doxygen, and should be escaped. *Sometimes* they
cause doc generation issues. Like in #17785

* Solution

Replace double quotes with single quotes
This commit is contained in:
Javier Lopez
2022-07-19 10:12:10 -05:00
committed by GitHub
parent b154d951e6
commit 61302fb391
2 changed files with 24 additions and 24 deletions

View File

@@ -2241,30 +2241,30 @@ end
--- <pre>
--- vim.filetype.add({
--- extension = {
--- foo = "fooscript",
--- foo = 'fooscript',
--- bar = function(path, bufnr)
--- if some_condition() then
--- return "barscript", function(bufnr)
--- return 'barscript', function(bufnr)
--- -- Set a buffer variable
--- vim.b[bufnr].barscript_version = 2
--- end
--- end
--- return "bar"
--- return 'bar'
--- end,
--- },
--- filename = {
--- [".foorc"] = "toml",
--- ["/etc/foo/config"] = "toml",
--- ['.foorc'] = 'toml',
--- ['/etc/foo/config'] = 'toml',
--- },
--- pattern = {
--- [".*/etc/foo/.*"] = "fooscript",
--- ['.*/etc/foo/.*'] = 'fooscript',
--- -- Using an optional priority
--- [".*/etc/foo/.*%.conf"] = { "dosini", { priority = 10 } },
--- ["README.(%a+)$"] = function(path, bufnr, ext)
--- if ext == "md" then
--- return "markdown"
--- elseif ext == "rst" then
--- return "rst"
--- ['.*/etc/foo/.*%.conf'] = { 'dosini', { priority = 10 } },
--- ['README.(%a+)$'] = function(path, bufnr, ext)
--- if ext == 'md' then
--- return 'markdown'
--- elseif ext == 'rst' then
--- return 'rst'
--- end
--- end,
--- },