diff options
| author | Dave Cheney <dave@cheney.net> | 2014-08-22 22:21:41 +1000 |
|---|---|---|
| committer | Dave Cheney <dave@cheney.net> | 2014-08-22 22:21:41 +1000 |
| commit | 3d3d5390834629a73b745900eb1a0aeda94d927d (patch) | |
| tree | 94b036ab351864a940359f99a09f9fb445c2db92 /src/pkg/path/filepath | |
| parent | 84b70df44c0092d1ce395cf22049d1e3af194c12 (diff) | |
| download | go-3d3d5390834629a73b745900eb1a0aeda94d927d.tar.xz | |
path, path/filepath: remove dead code
Fixes #8503.
Thanks to no.smile.face for the original report.
LGTM=bradfitz, r, ruiu
R=bradfitz, ruiu, r
CC=golang-codereviews
https://golang.org/cl/132730043
Diffstat (limited to 'src/pkg/path/filepath')
| -rw-r--r-- | src/pkg/path/filepath/path.go | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/src/pkg/path/filepath/path.go b/src/pkg/path/filepath/path.go index 7fa3b9b56a..d37fc9dfc8 100644 --- a/src/pkg/path/filepath/path.go +++ b/src/pkg/path/filepath/path.go @@ -452,13 +452,6 @@ func Dir(path string) string { i-- } dir := Clean(path[len(vol) : i+1]) - last := len(dir) - 1 - if last > 0 && os.IsPathSeparator(dir[last]) { - dir = dir[:last] - } - if dir == "" { - dir = "." - } return vol + dir } |
