Removed superfluous consts.
the build was successful
Details
the build was successful
Details
This commit is contained in:
parent
1a10ef6686
commit
ffb0438776
|
@ -1,6 +1,6 @@
|
|||
cmake_minimum_required (VERSION 3.1)
|
||||
project(xdgjson
|
||||
VERSION 0.2.2
|
||||
VERSION 0.2.3
|
||||
LANGUAGES CXX
|
||||
)
|
||||
|
||||
|
@ -13,7 +13,8 @@ set(CMAKE_CXX_STANDARD 14)
|
|||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||
set(CMAKE_CXX_EXTENSIONS OFF)
|
||||
|
||||
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -Wall")
|
||||
set(CMAKE_CXX_FLAGS
|
||||
"${CMAKE_CXX_FLAGS} -Wpedantic -Wall -Wextra -g -Og -fno-omit-frame-pointer")
|
||||
|
||||
include_directories(${LIBXDG_BASEDIR_INCLUDE_DIRS})
|
||||
include_directories(${JSONCPP_INCLUDE_DIRS})
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
#include <jsoncpp/json/json.h>
|
||||
#include "xdgjson.hpp"
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
int main()
|
||||
{
|
||||
xdgjson config("test.json", "xdgjson");
|
||||
config.read();
|
||||
|
|
|
@ -26,7 +26,7 @@ xdgjson::xdgjson(const string &filename, const string &subdir)
|
|||
_filepath /= filename;
|
||||
}
|
||||
|
||||
const bool xdgjson::read()
|
||||
bool xdgjson::read()
|
||||
{
|
||||
std::ifstream file(_filepath);
|
||||
if (file.is_open())
|
||||
|
@ -44,7 +44,7 @@ const bool xdgjson::read()
|
|||
}
|
||||
}
|
||||
|
||||
const bool xdgjson::write()
|
||||
bool xdgjson::write()
|
||||
{
|
||||
std::ofstream file(_filepath);
|
||||
if (file.is_open())
|
||||
|
|
|
@ -41,14 +41,14 @@ public:
|
|||
*
|
||||
* @return `true` on success
|
||||
*/
|
||||
const bool read();
|
||||
bool read();
|
||||
|
||||
/*!
|
||||
* @brief Write the file
|
||||
*
|
||||
* @return `true` on success
|
||||
*/
|
||||
const bool write();
|
||||
bool write();
|
||||
|
||||
/*!
|
||||
* @brief Returns a reference to the config as Json::Value
|
||||
|
|
Reference in New Issue