diff options
author | Robin Jarry <robin@jarry.cc> | 2023-10-26 00:03:43 +0200 |
---|---|---|
committer | Robin Jarry <robin@jarry.cc> | 2023-11-02 16:31:00 +0100 |
commit | 23ba54784a49fe13c665396c49a5ab3baa70ebd5 (patch) | |
tree | aa3ed90d331420a90c144c52e62a00a96062ba4c /worker/maildir/container.go | |
parent | 0b0095eeadaf7645b731f277c06e3f19e63ea981 (diff) | |
download | aerc-23ba54784a49fe13c665396c49a5ab3baa70ebd5.tar.gz |
linters: avoid crash when analyzing function call
When encountering a statement such as:
go functionName()
The identifier is not a local symbol but should be looked up in the
current package. Do not consider that all these statements will refer to
local variables.
The only way to do this is to run a second analyzer that depends on the
first one. Store all unresolved methods and functions into
a indirectCalls struct. Reuse that result in the second analyzer to
resolve the function declarations and check their bodies for the
defer log.PanicHandler() statement.
Fix one newly reported issues.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Reviewed-by: Tim Culverhouse <tim@timculverhouse.com>
Diffstat (limited to 'worker/maildir/container.go')
0 files changed, 0 insertions, 0 deletions