fixed here: https://github.com/nsf/gocode/pull/361/files
Not sure what I was thinking when I wrote that code. My bad. > On Jul 13, 2016, at 10:23 AM, Ian Lance Taylor <[email protected]> wrote: > > On Wed, Jul 13, 2016 at 2:43 AM, Anmol Sethi <[email protected]> wrote: >> Right here: >> https://github.com/nsf/gocode/blob/f535dc686130fcc7b942c504ce5903222a205ca3/autocompletecontext.go#L254 >> >> I have to annoyingly use filepath.ToSlash after just in case the user was on >> windows. > > I don't know what that code is doing, but the fact that you are > passing fpath to readdir makes me think that fpath is a path in the > file system, and that you should be using the path/filepath package > anyhow. Why are you using the path package here? (To be clear, the > path package is for things like URLs, and the path/filepath package is > for file system paths.) > > Ian > > > >>> On Jul 12, 2016, at 10:58 PM, Ian Lance Taylor <[email protected]> wrote: >>> >>> On Tue, Jul 12, 2016 at 5:17 PM, Anmol Sethi <[email protected]> wrote: >>>> Why is there no function in the path package to get relative paths, like >>>> filepath.Rel? >>> >>> When would you want to use it? >>> >>> Ian >> -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
