Skip to content

Commit

Permalink
tmp
Browse files Browse the repository at this point in the history
  • Loading branch information
rsteube committed Dec 2, 2023
1 parent b8eddd0 commit 977b766
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tokenslice.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,8 @@ func (t TokenSlice) WordbreakPrefix() string {
case QUOTING_STATE, QUOTING_ESCAPING_STATE, ESCAPING_QUOTED_STATE:
found = true
// TODO add value up to quote to prefix
if index := strings.LastIndexAny(last.RawValue, `"'`); index > -1 {
prefix = last.RawValue[:index] // TODO test - this is wrong
if index := strings.LastIndexAny(last.RawValue, `"'`); index > -1 { // TODO index needs to be stored during scanning
prefix = last.RawValue[:index] // TODO test - this is wrong (needs to be value up to rawvalue index -> just rescan the substring)
}
}

Expand Down

0 comments on commit 977b766

Please # to comment.