2012-07-25 52 views
5

对于Qt qmake variables我有时会看到不同的符号。

例子

$$PWD 
$${PWD} 

对于我来说,似乎工作一样,有什么区别?

回答

5

根据documentation这两个符号几乎相同。唯一的区别是the second notation allows you to append the contents of the variable to another value without separating the two with a space

+0

良好的提示,不知何故,我错过了这一点。谢谢 – 2012-07-26 10:08:29

+0

该链接后面的页面没有提到qmake,我在链接图中找不到“靠近”它的页面。 – Grault 2013-06-02 22:09:49

+0

@Jesdisciple非常感谢您通知我。确实,这个链接不再有效。我已经取代它。 – Bill 2013-06-03 07:56:32