Skip to content
Snippets Groups Projects
Commit cfcdf7e8 authored by Grzegorz Gach's avatar Grzegorz Gach
Browse files

Fix AFPSOFT-22 according to Scott Snyder suggestion.

Moved initialisation and definition of static const class members to
source files, becuase anyway the variables would have to be defined in
source files if they are ever bound to a reference. Lack of definition
can cause link failures, but often only in debug builds. See
<https://stackoverflow.com/questions/5391973/undefined-reference-to-static-const-int>


Former-commit-id: fd9a7636
parent 6735ff0a
Loading
/*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
*/
/**
* @file AFPClusterAlgID.h
* @author Grzegorz Gach <grzegorz.gach@cern.ch>
* @date 2017-04-14
*
* @brief Definitions of identification numbers of pixel clustering algorithms
*
*/
#include "xAODForward/AFPClusterAlgID.h"
const int xAOD::AFPClusterAlgID::singleHit = 0;
const int xAOD::AFPClusterAlgID::nearestNeighbour = 1;
/*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
*/
/**
* @file AFPPixelLayerID.cxx
* @author Grzegorz Gach <grzegorz.gach@cern.ch>
* @date 2017-10-02
*
* @brief Definitions of silicon layers (tracking) identification numbers in an AFP station.
*/
#include "xAODForward/AFPPixelLayerID.h"
const int xAOD::AFPPixelLayerID::firstFromIP = 0;
const int xAOD::AFPPixelLayerID::secondFromIP = 1;
const int xAOD::AFPPixelLayerID::thirdFromIP = 2;
const int xAOD::AFPPixelLayerID::fourthFromIP = 3;
/*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
*/
/**
* @file AFPStationID.cxx
* @author Grzegorz Gach <grzegorz.gach@cern.ch>
* @date 2017-10-02
*
* @brief Definitions of AFP stations identification numbers.
*/
#include "xAODForward/AFPStationID.h"
const int xAOD::AFPStationID::farA = 0;
const int xAOD::AFPStationID::nearA = 1;
const int xAOD::AFPStationID::nearC = 2;
const int xAOD::AFPStationID::farC = 3;
......@@ -44,8 +44,8 @@ namespace xAOD
class AFPClusterAlgID
{
public:
static const int singleHit = 0; ///< Single hit algorithm
static const int nearestNeighbour = 1; ///< Nearest neighbour algorithm
static const int singleHit; ///< Single hit algorithm
static const int nearestNeighbour; ///< Nearest neighbour algorithm
};
}
......
......@@ -57,10 +57,10 @@ namespace xAOD
class AFPPixelLayerID
{
public:
static const int fristFromIP = 0; ///< the silicon layer closest to the interaction point
static const int secondFromIP = 1; ///< the second silicon layer counting from the interaction point
static const int thirdFromIP = 2; ///< the third silicon layer counting from the interaction point
static const int fourthFromIP = 3; ///< the fourth (last) silicon layer counting from the interaction point
static const int firstFromIP; ///< the silicon layer closest to the interaction point
static const int secondFromIP; ///< the second silicon layer counting from the interaction point
static const int thirdFromIP; ///< the third silicon layer counting from the interaction point
static const int fourthFromIP; ///< the fourth (last) silicon layer counting from the interaction point
};
}
......
......@@ -46,10 +46,10 @@ namespace xAOD
class AFPStationID
{
public:
static const int farA = 0; ///< station with at Z = 217 m
static const int nearA = 1; ///< station with at Z = 205 m
static const int nearC = 2; ///< station with at Z = -205 m
static const int farC = 3; ///< station with at Z = -217 m
static const int farA; ///< station with at Z = 217 m
static const int nearA; ///< station with at Z = 205 m
static const int nearC; ///< station with at Z = -205 m
static const int farC; ///< station with at Z = -217 m
};
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment