2016-01-12 147 views
0

原因是什麼,GoogleTest爲什麼要使用參數計數參考?GoogleTest初始化參考

testing::InitGoogleTest(&argc, argv); 

(我的意思是:據我所知,這是一個輸入參數和沒有差別 是否提供值或地址)

回答

3

comments

// Initializes Google Test. This must be called before calling 
// RUN_ALL_TESTS(). In particular, it parses a command line for the 
// flags that Google Test recognizes. Whenever a Google Test flag is 
// seen, it is removed from argv, and *argc is decremented.