Commit 7865ec57 authored by Owen Arnold's avatar Owen Arnold
Browse files

refs #10878. Fix warnings.

Because json.h is exporting types with dll_export set, which in-turn export types without dll_export set, I have had to disable those specific warnings. We do not have control of this third-party component, so cannot fix the headers.
parent d611801b
......@@ -762,7 +762,7 @@ void PeaksWorkspace::saveNexus(::NeXus::File *file) const {
file->openData(name);
char *toNexus = new char[maxShapeJSONLength * np];
for (int ii = 0; ii < np; ii++) {
for (size_t ii = 0; ii < np; ii++) {
std::string rowStr = shapes[ii];
for (size_t ic = 0; ic < rowStr.size(); ic++)
toNexus[ii * maxShapeJSONLength + ic] = rowStr[ic];
......
#ifndef MANTID_DATAOBJECTS_PEAKSHAPENONETEST_H_
#define MANTID_DATAOBJECTS_PEAKSHAPENONETEST_H_
#ifdef _WIN32
#pragma warning(disable : 4251)
#endif
#include <cxxtest/TestSuite.h>
#include <jsoncpp/json/json.h>
#include "MantidDataObjects/NoShape.h"
......
#ifndef MANTID_DATAOBJECTS_PEAKSHAPESPHERICALFACTORYTEST_H_
#define MANTID_DATAOBJECTS_PEAKSHAPESPHERICALFACTORYTEST_H_
#ifdef _WIN32
#pragma warning(disable : 4251)
#endif
#include <cxxtest/TestSuite.h>
#include <gmock/gmock.h>
#include <jsoncpp/json/json.h>
......
#ifndef MANTID_DATAOBJECTS_PEAKSHAPESPHERICALTEST_H_
#define MANTID_DATAOBJECTS_PEAKSHAPESPHERICALTEST_H_
#ifdef _WIN32
#pragma warning(disable : 4251)
#endif
#include <cxxtest/TestSuite.h>
#include <jsoncpp/json/json.h>
......@@ -109,6 +113,7 @@ public:
Json::Value output;
TSM_ASSERT("Should parse as JSON", reader.parse(json, output));
TS_ASSERT_EQUALS(algorithmName, output["algorithm_name"].asString());
TS_ASSERT_EQUALS(algorithmVersion, output["algorithm_version"].asInt());
TS_ASSERT_EQUALS(frame, output["frame"].asInt());
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment