[Tutor] Are Empty "Placeholder" Functions possible?

Lloyd Kvam python at venix.com
Thu May 26 21:27:21 CEST 2005


An alternative to pass is
	raise NotImplementedError

This has the advantage/disadvantage of providing a meaningful exception
when you start testing and forget to provide some processing logic for a
stub function.  pass will simply return None when used for a function
body.  I nearly always use the NotImplementedError exception now in my
code as the place holder.


-- 
Lloyd Kvam
Venix Corp



More information about the Tutor mailing list