`targetIsDirectory` slipped through the code review of
{D6679}/{rBafb1a64ccb81}.
`BLI_is_dir` exists to check for directory status of a file.
Remove some `else-after-return`s.
Use `r_` prefix for return value arguments, and move it to the end
in the list of arguments.
This adds support for macOS aliases in addition to symlinks. It also adds
support for hidden, readonly and system file attributes.
Contributed by Ankit (ankitm) with modifications by me.
Differential Revision: https://developer.blender.org/D6679