doc: another example of using def