base inline functions