add documentation for with_nested
Merge pull request #3530 from candeira/with_nested

add documentation for with_nested