MCPcopy Create free account
hub / github.com/LibreSprite/LibreSprite / join_path

Function join_path

src/base/path.cpp:135–146  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

133}
134
135std::string join_path(const std::string& path, const std::string& file)
136{
137 std::string result(path);
138
139 // Add a separator at the end if it is necessay
140 if (!result.empty() && !is_path_separator(*(result.end()-1)))
141 result.push_back(path_separator);
142
143 // Add the file
144 result += file;
145 return result;
146}
147
148std::string remove_path_separator(const std::string& path)
149{

Callers 15

make_all_directoriesFunction · 0.85
list_filesFunction · 0.85
TESTFunction · 0.85
add_frame_formatFunction · 0.85
isPortableMethod · 0.85
includeBinDirMethod · 0.85
includeHomeDirMethod · 0.85
includeUserDirMethod · 0.85
includeDesktopDirMethod · 0.85
file_system.cppFile · 0.85
createDirectoryMethod · 0.85
get_fileitem_by_pathFunction · 0.85

Calls 3

is_path_separatorFunction · 0.85
emptyMethod · 0.45
endMethod · 0.45

Tested by 1

TESTFunction · 0.68