#pragma once #include "file.h" namespace cppfs { /* file */ const file& file::remove() const { using namespace std::string_literals; auto& s = _path.str(); if (unlink(s.c_str())) throw cppcore::error_exception("Unable to remove file: "s + _path.str(), errno); return *this; } }