String platformPath(const String& path, PathStyle style)
{
  if (style == WindowsPath)
    return sb_replace(path, "/", "\\", -1);
  else if (style == PosixPath)
    return sb_replace(path, "\\", "/", -1);
  else
    return path;
}
Exemplo n.º 2
0
static String modifyCXXStandard(const String& val, const String& prefix, const VariableCollectionHierarchy& vch) {
    return prefix + sb_replace(val, "++0x", "++11", -1);
}
Exemplo n.º 3
0
static void expandString(std::string& str, const StringMap& params)
{
  for (auto paramKV : params) {
    str = sb_replace(str, paramKV.first, paramKV.second, -1);
  }
}