deprecate LOCAL_STATIC_LOCK

This construct is fairly useless.
Doesn't prevent ctor ordering problems.
This commit is contained in:
Michael Davidsaver
2017-12-28 11:23:29 -06:00
parent 6465ab3b6d
commit 207c24a4fd
2 changed files with 3 additions and 3 deletions

View File

@@ -26,7 +26,6 @@
#include <pv/pvIntrospect.h>
#include <pv/factory.h>
#include <pv/serializeHelper.h>
#include <pv/localStaticLock.h>
using std::tr1::static_pointer_cast;
using std::size_t;
@@ -1456,7 +1455,6 @@ FieldConstPtr FieldCreate::deserialize(ByteBuffer* buffer, DeserializableControl
// TODO replace with non-locking singleton pattern
const FieldCreatePtr& FieldCreate::getFieldCreate()
{
LOCAL_STATIC_LOCK;
static FieldCreatePtr fieldCreate;
static Mutex mutex;

View File

@@ -9,11 +9,13 @@
#ifndef LOCALSTATICLOCK_H
#define LOCALSTATICLOCK_H
#include <compilerDependencies.h>
#include <pv/lock.h>
#include <shareLib.h>
epicsShareExtern epics::pvData::Mutex& getLocalStaticInitMutex();
epicsShareExtern epics::pvData::Mutex& getLocalStaticInitMutex() EPICS_DEPRECATED;
#if defined(__GNUC__) && __GNUC__ >= 4
// noop