Document Limitations [DI17] [WHAT]

Document Limitations [DI17] [WHAT]

Tip DI17

Few functions will be able to handle everything. Make sure to document any limitations, restrictions, caveats, etc. so that programmers using a function have awareness and can account for them appropriately.

Limitations that apply to specific parameters or return values may be best documented for those entities specifically, but any function-level limitations should be documented at a function-overview level.

Examples of some kinds of limitations include:

  • Limits on data sizes

  • Limited accuracy or precision

  • Different behavior when errors occur

  • Undefined results in some cases

  • Things that would break the function

The following demonstrate several examples of how a basic summary of a function can be extended to document important function-level limitations:

 

Say goodbye to blindsided code updates ad.png