Clang-tidy static analysis (#3222)
* Clang-tidy static analysis * Modernise checks * Google coding standard checks * Identifier renaming according to Google style
This commit is contained in:
@@ -30,16 +30,16 @@ typedef uint64_t bst_ulong; // NOLINT(*)
|
||||
|
||||
|
||||
/*! \brief handle to DMatrix */
|
||||
typedef void *DMatrixHandle;
|
||||
typedef void *DMatrixHandle; // NOLINT(*)
|
||||
/*! \brief handle to Booster */
|
||||
typedef void *BoosterHandle;
|
||||
typedef void *BoosterHandle; // NOLINT(*)
|
||||
/*! \brief handle to a data iterator */
|
||||
typedef void *DataIterHandle;
|
||||
typedef void *DataIterHandle; // NOLINT(*)
|
||||
/*! \brief handle to a internal data holder. */
|
||||
typedef void *DataHolderHandle;
|
||||
typedef void *DataHolderHandle; // NOLINT(*)
|
||||
|
||||
/*! \brief Mini batch used in XGBoost Data Iteration */
|
||||
typedef struct {
|
||||
typedef struct { // NOLINT(*)
|
||||
/*! \brief number of rows in the minibatch */
|
||||
size_t size;
|
||||
/*! \brief row pointer to the rows in the data */
|
||||
@@ -66,7 +66,7 @@ typedef struct {
|
||||
* \param handle The handle to the callback.
|
||||
* \param batch The data content to be set.
|
||||
*/
|
||||
XGB_EXTERN_C typedef int XGBCallbackSetData(
|
||||
XGB_EXTERN_C typedef int XGBCallbackSetData( // NOLINT(*)
|
||||
DataHolderHandle handle, XGBoostBatchCSR batch);
|
||||
|
||||
/*!
|
||||
@@ -80,9 +80,8 @@ XGB_EXTERN_C typedef int XGBCallbackSetData(
|
||||
* \param set_function_handle The handle to be passed to set function.
|
||||
* \return 0 if we are reaching the end and batch is not returned.
|
||||
*/
|
||||
XGB_EXTERN_C typedef int XGBCallbackDataIterNext(
|
||||
DataIterHandle data_handle,
|
||||
XGBCallbackSetData* set_function,
|
||||
XGB_EXTERN_C typedef int XGBCallbackDataIterNext( // NOLINT(*)
|
||||
DataIterHandle data_handle, XGBCallbackSetData *set_function,
|
||||
DataHolderHandle set_function_handle);
|
||||
|
||||
/*!
|
||||
@@ -216,11 +215,9 @@ XGB_DLL int XGDMatrixCreateFromMat(const float *data,
|
||||
* \param nthread number of threads (up to maximum cores available, if <=0 use all cores)
|
||||
* \return 0 when success, -1 when failure happens
|
||||
*/
|
||||
XGB_DLL int XGDMatrixCreateFromMat_omp(const float *data,
|
||||
bst_ulong nrow,
|
||||
bst_ulong ncol,
|
||||
float missing,
|
||||
DMatrixHandle *out,
|
||||
XGB_DLL int XGDMatrixCreateFromMat_omp(const float *data, // NOLINT
|
||||
bst_ulong nrow, bst_ulong ncol,
|
||||
float missing, DMatrixHandle *out,
|
||||
int nthread);
|
||||
/*!
|
||||
* \brief create a new dmatrix from sliced content of existing matrix
|
||||
|
||||
Reference in New Issue
Block a user