Commit Graph

13 Commits

Author SHA1 Message Date
Kovid Goyal
405f5ce148 Use stdlib maps/slices 2024-06-24 07:54:13 +05:30
Kovid Goyal
5e125c35d1 hints kitten: Report the pattern used when no matches are found 2024-04-20 05:14:03 +05:30
Kovid Goyal
8cc2cad4d9 Use list of legal chars in URL from the WHATWG standard
Notably this excludes some ASCII chars: <>{}[]`|
See https://url.spec.whatwg.org/#url-code-points

Fixes #7095
2024-02-05 13:27:22 +05:30
Kovid Goyal
70a588cb36 ... 2023-10-17 15:23:43 +05:30
Kovid Goyal
4f72bb9894 Replace utils.Once with stdlib sync.OnceValue 2023-08-09 12:08:42 +05:30
Kovid Goyal
49ea26968c Bump go version to 1.21
Allows us to use the much faster builtin min/max functions
for two variable min/max
2023-08-09 11:58:16 +05:30
Kovid Goyal
0873e3ea09 ... 2023-05-31 07:22:49 +05:30
Kovid Goyal
9bbb2a9ef4 Fix #6315 2023-05-31 07:08:55 +05:30
Kovid Goyal
e59e42a6c2 simplify API of utils.Once 2023-05-26 22:42:07 +05:30
Kovid Goyal
c101a6acb0 Implement a dedicated function for word matching rather than relying on a regex and being at the mercy of the vagaries of regex implementations 2023-05-12 15:43:56 +05:30
Kovid Goyal
65f8bb7397 hints kitten: Switch to using a regex engine that supports lookaround
Note that we loose unicode char matching for --type=word because of
https://github.com/dlclark/regexp2/issues/65 and of course user regexps
cant use \p{N} escapes any more. Hopefully regexp2 will add support for
these soon-ish. IMO lookaround is more important than \p.

Fixes #6265
2023-05-12 12:24:59 +05:30
Kovid Goyal
1fc4e53bea hints kitten: Fix a regression in 0.28.0 that broke using sub-groups in regexp captures
Fixes #6228
2023-04-30 21:16:24 +05:30
Kovid Goyal
ff55121094 Move the kittens Go code into the kittens folder 2023-03-27 13:06:02 +05:30