源码可在https://github.com/learnmoreonce/SLAM 下载
文件:common/mutex.h
/*
common/mutex.h主要是对c++11 的mutex的封装。
*/
#ifndef CARTOGRAPHER_COMMON_MUTEX_H_
#define CARTOGRAPHER_COMMON_MUTEX_H_
#include <condition_variable>
#include <mutex>
#include "cartographer/common/time.h"
namespace cartographer {
namespace common {
/*不使用clang时,以下宏定义全部为空操作.故看见宏定义时可暂时忽略*/
// Enable thread safety attributes only with clang.
// The attributes can be safely erase