動名詞(gerund)在拉丁語和英語語法,是一種非限定动词形式,可以有名詞的功能性。
在英語動名詞的結尾為 -ing(例如:I enjoy playing basketball./我很喜歡打籃球/);同樣的動詞形式也可作為英語現在分詞,其可能具有形容詞或副詞的功能,或作為一個純粹的動詞性名詞(Verbal noun)。動名詞即在表示動詞的動作。例如,playing(玩)是表示to play(去玩)的動作。在某些情況下,一個名詞以(-ing)結尾有時作為一個動名詞(如"I like building.(我喜歡建築)"/"I like building things.(我喜歡建築的東西)","I like painting.(我喜歡畫畫)"/"I like painting pictures.(我喜歡繪畫的照片)",以及"I like writing.(我喜歡寫作)"/"I like writing novels.(我喜歡寫小說)"),而在其他時候作為一個非動名詞而表示出從一個動作所產生的產品(如"I work in that building.(我在那棟樓工作)","That is a good painting.(這是一幅很好的畫)",和"Her writing is good.(她的文筆不錯)")。後者的情況下經常可以由一個出現在限定詞(determiner)之前的名詞區分開來,在這些範例中比如:"that(那個)",或"her(她)"等限定詞。
10
1
I have a function that searches a vector of iterators and returns the iterator if its names matches a string passed as an argument. koalaGraph::PVertex lookUpByName(std::string Name, std::vector<koalaGraph::PVertex>& Vertices) { for (size_t i = 0; i < Vertices.size(); i++) { if(Vertices[i]->info.name == Name) return Vertices[i]; } } My question is how can I implement this as a lambda, to use it in connection with std::find_if ? I'm trying this: std::vector<koalaGraph::PVertex> V; std::string Name; std::find_if(V.begin(), V.end(), [&Name]() {return Name == V->info.name;}) But it says that V an enclosing-function local variable cannot be referenced in a lambda body unless it is in the capture list.
...
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}
4
1
I am installing hackintosh in virtualbox on ubuntu, but when I try to start, I get above error. Here are some more details, Result Code: NS_ERROR_FAILURE (0x80004005) Component: ConsoleWrap Interface: IConsole {872da645-4a9b-1727-bee2-5585105b9eed} How can I solve this issue?
16.04 virtualbox
share | improve this question
asked Oct 22 '17 at 15:10
luv.preet luv.preet
1,502 4 13 29
...