如何将类似的符号粘贴到 PHPDoc block 中?
*/
@
例如:
/**
* Please use these symbol "@" with symbols "*/" as well.
*/
在 documentation 中找不到它.
最佳答案
来自phpdoc.org我们可以阅读手册:
if you need an actual "@" in your DocBlock's description parts, you should be careful to either ensure it is not the first character on a line, or else escape it ("\@")
还有新的1.2.0rc1:
If you need to use the closing comment "*/" in a DocBlock, use the special escape sequence "{@*}."
/**
* <code>
* \@require 'config.php'
* Example comment {@*}
* </code>
*/
将呈现为:
/**
* <code>
* @require 'config.php'
* Example comment */
* </code>
*/
关于php - 如何在 PHP 中的 PHPDocumentor block 中粘贴特殊符号,例如 "*/"?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32504450/