added comments to inline functions