summaryrefslogtreecommitdiff
path: root/src/pkg/path/filepath/path_unix.go
diff options
context:
space:
mode:
authorOndřej Surý <ondrej@sury.org>2011-09-13 13:13:44 +0200
committerOndřej Surý <ondrej@sury.org>2011-09-13 13:13:44 +0200
commit9464a0c36318f8a801c07d6874bd0cea40f12504 (patch)
treef0178491c19d4f1ebc7b92eede86690998466480 /src/pkg/path/filepath/path_unix.go
parentba9fda6068cfadd42db0b152fdca7e8b67aaf77d (diff)
parent5ff4c17907d5b19510a62e08fd8d3b11e62b431d (diff)
downloadgolang-9464a0c36318f8a801c07d6874bd0cea40f12504.tar.gz
Merge commit 'upstream/60' into debian-sid
Diffstat (limited to 'src/pkg/path/filepath/path_unix.go')
-rw-r--r--src/pkg/path/filepath/path_unix.go9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/pkg/path/filepath/path_unix.go b/src/pkg/path/filepath/path_unix.go
index ea555fc0e..b2a4151c1 100644
--- a/src/pkg/path/filepath/path_unix.go
+++ b/src/pkg/path/filepath/path_unix.go
@@ -11,8 +11,13 @@ func IsAbs(path string) bool {
return strings.HasPrefix(path, "/")
}
-// volumeName returns the leading volume name on Windows.
+// VolumeName returns the leading volume name on Windows.
// It returns "" elsewhere.
-func volumeName(path string) string {
+func VolumeName(path string) string {
return ""
}
+
+// HasPrefix tests whether the path p begins with prefix.
+func HasPrefix(p, prefix string) bool {
+ return strings.HasPrefix(p, prefix)
+}