title: Golang check if string is valid path
body: <p>The Golang filepath module (<a href="https://golang.org/pkg/path/filepath/">https://golang.org/pkg/path/filepath/</a>) contains a few functions for manipulating paths and <code>os.Stat</code> can be used to check if a file exists. Is there a way to check if a string actually forms a valid path at all (regardless of whether there's a file at that path or not)?</p>