shouldn't the definition be permissive rather than rejective?
any legally utf-8-encoded printable unicode char, as defined by XXX, with the
exception of
the ascii frog list
spaces
FFFD if it's printable (not sure)
PTAL.
Added replacement char.
On Wed, Feb 22, 2012 at 1:43 PM, Rob 'Commander' Pike <r@google.com> wrote:
> shouldn't the definition be permissive rather than rejective?
Not sure. For one, "printable" seems less clearly defined that this
list (which corresponds exactly to what is implemented), and it's a
restriction, so "reject" seems fitting.
I'll try to change it if you feel strongly about it.
- gri
>
> any legally utf-8-encoded printable unicode char, as defined by XXX, with the
exception of
> the ascii frog list
> spaces
> FFFD if it's printable (not sure)
>
I think rejective is okay: I intended to allow nearly everything
except problematic ASCII characters. On that note I think
we have to allow ~, which I believe gets used in launchpad.net
import paths today.
Russ
PTAL
(Also updated: http://codereview.appspot.com/5683077)
On Wed, Feb 22, 2012 at 2:07 PM, Russ Cox <rsc@golang.org> wrote:
> I think rejective is okay: I intended to allow nearly everything
> except problematic ASCII characters. On that note I think
> we have to allow ~, which I believe gets used in launchpad.net
> import paths today.
>
> Russ
for the discussion so far, the code is fine, but i believe it's a mistake to
allow non-printable characters in a path, and it's very easy to define what
printable means, just as easy as to define what space means.
in short, i still prefer my form
-rob
On 23 February 2012 10:46, Rob 'Commander' Pike <r@google.com> wrote:
> for the discussion so far, the code is fine, but i believe it's a mistake to
allow non-printable characters in a path, and it's very easy to define what
printable means, just as easy as to define what space means.
>
> in short, i still prefer my form
I also prefer to provide a list of acceptable characters. Something we
haven't anticipated may bite us later.
Implementation restriction: A compiler may restict ImportPaths to be
non-empty strings using only Unicode's L, M, N, P, and S categories
(the definition of Graphic, without spaces)
and may also exclude the ASCII characters
<code>!"#$%&'()*,:;<=>?[\]^`{|}</code>.
Issue 5688074: code review 5688074: go spec: import path implementation restriction
(Closed)
Created 13 years ago by gri
Modified 13 years ago
Reviewers:
Base URL:
Comments: 1