---@diagnostic disable: missing-return, lowercase-global
---@meta

---@param event string
---@param filter function
---Adds a function to filter or alter messages to the chat display system. The filter function will be called each time a message is sent to one of the default chat frames (ChatFrame1, ChatFrame2, ..., ChatFrame7). The function will be passed the chat frame object that the message is being added to, along with the event that caused the messages to be added, and the arguments to that event. A filter function may return true if the message should be filtered , or false if the message should be displayed. Following this boolean flag, the message can return a list of (possibly) altered arguments to be passed to the next filter function. Note that your function will be called at least once for every ChatFrame the message-event is registered for. Currently (due to what appears to be a bug) the filter is actually called twice for each frame. Due to this non-deterministic calling, your filter function should not have side-effects. See examples for details.
function ChatFrame_AddMessageEventFilter(event, filter) end
