Added support for priorities in stubs. Supports kelveden/milli#19.