support generic method, trim None field
fix builds for 2.10
Merge pull request #29 from jilen/macro_enchance

support generic method, trim None field