阅读背景:

c++模板元编程,“如果是静态的”变通——它能改进吗?

来源:互联网 

I have a function that scans the user's file system, fills a vector with the paths, then either sorts it or not. Since the user should be able to decide at compile-time whether he wants the vector sorted or not, I use templates and helper classes in place of a much desired (but not existing) "static if".I have a function that scans the user's file sy




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: