每个人都知道提示指令.但是,通过查看各种模块,我学到了什么,例如,不赞成接受字符串-literal-以与$MESSAGE相同的方式发出:
procedure StinkStr(S: string); deprecated 'You are unemployed now.';
然而,文档对此有点谦虚(最高版本我手上是D2010),我讨厌精确科学中的猜测 – 问题是:
>记录此语法的位置?
>和,自哪个版本可用?
更正:仅接受字符串文字,拒绝常量(外部).
解决方法
这里记录了
http://docwiki.embarcadero.com/RADStudio/en/Deprecated
正如上面提到的评论,它似乎已经在Delphi 2009中引入.另一个参考是http://www.tindex.net/Language/deprecatedwithcomment.html