MCPcopy Create free account
hub / github.com/catboost/catboost / SlashFolderLocal

Function SlashFolderLocal

util/folder/dirut.cpp:14–27  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

12#include <util/system/yassert.h>
13
14void SlashFolderLocal(TString& folder) {
15 if (!folder) {
16 return;
17 }
18#ifdef _win32_
19 size_t pos;
20 while ((pos = folder.find('/')) != TString::npos) {
21 folder.replace(pos, 1, LOCSLASH_S);
22 }
23#endif
24 if (folder[folder.size() - 1] != LOCSLASH_C) {
25 folder.append(LOCSLASH_S);
26 }
27}
28
29#ifndef _win32_
30

Callers 1

RemoveDirWithContentsFunction · 0.85

Calls 4

findMethod · 0.45
replaceMethod · 0.45
sizeMethod · 0.45
appendMethod · 0.45

Tested by

no test coverage detected