/*
- * Copyright 2015 Facebook, Inc.
+ * Copyright 2017 Facebook, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
*/
#include <folly/experimental/RCUUtils.h>
-#include <folly/Portability.h>
#include <folly/ThreadLocal.h>
-
namespace folly {
namespace {
return ret;
}
+RCUReadLock& RCUReadLock::instance() {
+ // Both lock and unlock are static, so no need to worry about destruction
+ // order
+ static RCUReadLock instance;
+ return instance;
+}
}