Commit Graph

4 Commits

Author SHA1 Message Date
Anders Eknert 8a6000dd8c Enable static check of consistent receiver names (#9008)
Style thing really but I think one that makes sense. I renamed only by
what was already the most popular option.

Tested building against Go 1.27 to make sure I didn't mess that up.

Signed-off-by: Anders Eknert <anders.eknert@apple.com>
2026-08-12 13:19:42 -05:00
Anders Eknert b7c9658c4e perf: reduce allocations in index lookup (#8835)
While we previously cached and reused trie traveral result from indexing
lookups, simply `clear`ing the tr.unordered map meant we still had to
allocate every time we appended to its slice values. This change fixes
that, along with some general cleanups in index.go — including an
audacious attempt to sneak in `util.Or` from Regal!

The improvement should reflect nicely across many benchmarks in OPA, as
pretty much all evaluations do indexing lookups. The Regal benchmark is
quite convincing, with 800k allocations saved in linting the Regal
bundle:

```
449648097 ns/op    1234775834 B/op    34886194 allocs/op
449672806 ns/op    1226927914 B/op    34045124 allocs/op
```

Signed-off-by: Anders Eknert <anders.eknert@apple.com>
2026-07-01 19:46:29 +00:00
Johan Fylling bd872b8fb4 ast: and/or parsing (#8687)
resolves: #8677

Signed-off-by: Johan Fylling <johan.dev@fylling.se>
2026-05-22 18:04:34 +02:00
Johan Fylling 670d2e2556 ast, topdown: Add not AST node type (#8427)
Disabled by default. To enable, `not` future keyword must be present in capabilities and imported into Rego module.

Implements: #8391

Signed-off-by: Johan Fylling <johan.dev@fylling.se>
2026-03-30 18:12:57 +02:00