lairworks / nas2d-core

NAS2D is an open source, object oriented 2D game development framework written in portable C++.
http://nas2d.lairworks.com
zlib License
10 stars 5 forks source link

Make lexical `Filesystem` methods `static` #1077

Closed DanRStevens closed 1 year ago

DanRStevens commented 1 year ago

Some Filesystem methods work on path strings in a lexical manner, without regard to any actual filesystem object. These methods don't require a Filesystem object to be instantiated first. As such, they have been made static.

Making these methods static makes it easier to extract helper lambdas in the unit test code. This is useful since changing paths to use std::filesystem::path instead of std::string require some updates to the tests using these checks, so centralizing the checks makes the update easier.

Reference: #973