diff options
| author | hopehook <hopehook.com@gmail.com> | 2022-08-04 10:12:20 +0800 |
|---|---|---|
| committer | Matthew Dempsky <mdempsky@google.com> | 2022-08-04 20:35:21 +0000 |
| commit | 91d5ce3def7c967b23de37546439bb4714e26e8a (patch) | |
| tree | 5b4c435f91279ba82eaed7432339f621f5c39c50 /src/cmd/asm/internal | |
| parent | 39728f412d5fb6d97568cc84a42f1caf07dbaedc (diff) | |
| download | go-91d5ce3def7c967b23de37546439bb4714e26e8a.tar.xz | |
all: clean up TODO after fixing issue 44505
For #44505
Change-Id: I89220be02372b5340cb987bf2ac870a9346a8c8f
Reviewed-on: https://go-review.googlesource.com/c/go/+/421079
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Diffstat (limited to 'src/cmd/asm/internal')
| -rw-r--r-- | src/cmd/asm/internal/lex/tokenizer.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cmd/asm/internal/lex/tokenizer.go b/src/cmd/asm/internal/lex/tokenizer.go index 4db88e20c3..f60f7a11af 100644 --- a/src/cmd/asm/internal/lex/tokenizer.go +++ b/src/cmd/asm/internal/lex/tokenizer.go @@ -5,6 +5,7 @@ package lex import ( + "go/build/constraint" "io" "os" "strings" @@ -109,8 +110,7 @@ func (t *Tokenizer) Next() ScanToken { } text := s.TokenText() t.line += strings.Count(text, "\n") - // TODO: Use constraint.IsGoBuild once #44505 fixed. - if strings.HasPrefix(text, "//go:build") { + if constraint.IsGoBuild(text) { t.tok = BuildComment break } |
