Improved comments on public functions and variables as suggested in https://github.com/openjournals/joss-reviews/issues/1592#issuecomment-514946444

This commit is contained in:
eidheim 2019-07-26 09:28:20 +02:00
commit ed46b43fa7
7 changed files with 130 additions and 57 deletions

View file

@ -69,7 +69,7 @@
THREAD_ANNOTATION_ATTRIBUTE__(no_thread_safety_analysis)
namespace SimpleWeb {
/// Defines an annotated interface for mutexes.
/// Mutex class that is annotated for Clang Thread Safety Analysis.
class CAPABILITY("mutex") Mutex {
std::mutex mutex;
@ -83,6 +83,7 @@ namespace SimpleWeb {
}
};
/// Scoped mutex guard class that is annotated for Clang Thread Safety Analysis.
class SCOPED_CAPABILITY LockGuard {
Mutex &mutex;
bool locked = true;