Project

General

Profile

Optimization #3160

clean up error codes

Added by Victor Julien about 1 month ago. Updated 7 days ago.

Status:
New
Priority:
Normal
Assignee:
Target version:
Effort:
Difficulty:
Label:

Description

The list of error codes defined in util-error.h is massive and often not very helpful. One of the original ideas was to have a list of unique codes, but that hasn't materialized. The codes are often reused, lots are redundant and some may be unused.

Also, the codes often don't add all that much to the per error/warning custom message.

Consider a much simpler scheme. E.g. something like the errno approach (or perhaps exactly this).

History

#1

Updated by Jason Ish 16 days ago

By the errno approach are you referring to a more limited set of error codes? Or something functional like a thread local error variable as well?

#2

Updated by Victor Julien 7 days ago

Was thinking about a limited set of codes (EINVAL, ENOMEM, ENOENT, etc). But it would be good to consider how these errors would be passed along too.

Also available in: Atom PDF