baseNameOf: Don't copy paths to the store first

This is technically a breaking change, but I doubt anyone relies on the existing semantics. I'd expect `baseNameOf ./foo` to be `"foo"`, not `"somehash-foo"`. Currently I'm doing `baseNameOf (toString ./foo)` everywhere I need `baseNameOf`.