Yasuhiro Matsumoto | 0f4510b | 2011-05-29 13:03:49 +1000 | [diff] [blame] | 1 | // Copyright 2011 The Go Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style |
| 3 | // license that can be found in the LICENSE file. |
| 4 | |
Dave Cheney | 7c8280c | 2014-02-25 09:47:42 -0500 | [diff] [blame] | 5 | // +build darwin dragonfly freebsd linux nacl netbsd openbsd solaris |
Russ Cox | 2715956 | 2011-09-15 16:48:57 -0400 | [diff] [blame] | 6 | |
Yasuhiro Matsumoto | 0f4510b | 2011-05-29 13:03:49 +1000 | [diff] [blame] | 7 | package os |
| 8 | |
| 9 | const ( |
| 10 | PathSeparator = '/' // OS-specific path separator |
| 11 | PathListSeparator = ':' // OS-specific path list separator |
| 12 | ) |
| 13 | |
Josh Bleecher Snyder | 2adc4e8 | 2015-02-17 15:44:42 -0800 | [diff] [blame] | 14 | // IsPathSeparator reports whether c is a directory separator character. |
Yasuhiro Matsumoto | 0f4510b | 2011-05-29 13:03:49 +1000 | [diff] [blame] | 15 | func IsPathSeparator(c uint8) bool { |
| 16 | return PathSeparator == c |
| 17 | } |