[master] add macros to generate-docs
[master] add assert to generate-docs