Reserved IDs

The mousetrap library sets aside some identifiers defined in an enum to signify certain things internally. The declaration of the enum is in <mousetrap/mousetrap.h>

The internal function mousetrap_get_next_id starts at the first number after the last reserved identifier(MT_RESERVED_LAST) in this enum. If you wish to use your own identifier generation scheme, identifiers less than or equal to MT_RESERVED_LAST will cause undesirable results.

MT_TRANSPARENCY Used to denote transparency information in a mousetrap.
MT_PLACEHOLDER Used for arbitrary things. Mostly internal, but also a failure value from mousetrap_lookup_id.
MT_RESERVED_LAST Included to make client code work easily when/if more reserved IDs are added to the system.

Copyright © 2001 Ben Smith