Skip to content

Commit

Permalink
Merge fe1f07d into 15c4251
Browse files Browse the repository at this point in the history
  • Loading branch information
iphydf committed Jan 24, 2018
2 parents 15c4251 + fe1f07d commit 3060014
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 13 deletions.
4 changes: 4 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ env:
- secure: "mZFIQOfFLWasqa9LuPvP/ZrJ1JSp+/iYzU5ARYDh+ySjCZPoAUwTLICluqYbKBVmLK+f65iAjbWVYKgK+i14I3txaXw03CnU+ZZBZE4Q/0RWdMFNG8xk5b3ggXy6CBxBNBfrlyfNB3JCgtFayHdekwIwqrQpVcK3DUrpFkMyRiKqeywii7HkcXHdKeg0ZdHbhZHUZu7X23+f5J7zoj20vh7Fxck7iPzOG5lCFEWueS942i6gZkMaJijQArEEGGZw8FFAR+lsq5EKhicHJuJbwRQzHMLStMz7vl34LmiHXTJxVVv4CEeFOxWF0crowKPdaSWXQCL1enl5vYH0oLrr+ZR+ZSo5sFtdnmujpDTQaWfTA06kS7MhWGE1/LT/9W5RGCZy/FuRafiAWjUHz2bqTKP07Cz6LTG4+LngvnQ4eHS/1bXJ+eLy2D37iURVsnHA817p+wRO4sfWmV1oVSylbM7tEcG9jVnUHLXpDjNR5PpdUDpbN3lrxa0ZIwL9Uyu1WkuIgaBGflfp2gpgeK1yLUMHmnZkCNGzTz3+j0zPXVOex68ac8X3FVvKoj4FhGhN+YeXzMBH+igetRPE9Y32+Rq8/e9zrj+kcqNmCW1+lc6axaCPDT2TKjKUV6dy2+bYz8VOUC9dRTTEoaHnIgbgHjt1No+vT2jyXxu6e0kntqQ="
- secure: "SfREeQcDNMjYdGBlIDegl54Wr28hDIpIcbtqNNuC/LQzN8tLkj4XnC28MLcBsxaNckbUQv9+8sR9yE6flQaXwerfnDXUX97iTtmH6qMZswTGiJTo2olJ0K1XArGPQoRLuZ37+TW44c4Gh7aEQZZX1a/0YcT2v+jQ1LBOewnY9GRTK4941bHiIWbpDoknBjqOEcfRQd0ZOWHm6hbnDQKWPwvKl4KVh13gBefiTBd0uMPb4LwnKMKHSzwjpZTI0b9ykvDGZR/Ad4Eu6f+8pMuEuBZr5a+vhm+OD+b23iDpnHszk5+6q589eEX/KqXUoFat0lvF+b6yHFxdXALlDXgL+YmN3G5mW665uSHH7aYe23kGkMIijgYHu/35DCij6T3u4M/GpW9UHuIX20U07B25cOpmNibVBQ11iOV/f8FD/wQw1QtvQ3BWNMFTKI21ZOE//PGRfLZP6pinrZKAhfcdteItjEdtWuS+vvhRh73VKVPRtPofLRvcfGUp+KHYVSf7a1EbJ6elFNopFQxPh2nMavmHx6gFot6UPnEA/POMZg6P4jLxThkCy/3Ixe72ObJpod1O+V84UkZx3dev/2n0Ae+MCaXZOcYjCSDDzDPirPq+fQ8OkrMxREobm+LMx4r1ZtF66TNwdjTIb4CpfOl3nWM8vkcK5hVo0ocnO0QBGL0="

stages:
- name: Release
if: type IN (push, api, cron)

matrix:
include:
# Test builds first, since they don't upload things.
Expand Down
1 change: 0 additions & 1 deletion BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ cc_binary(
"-Wno-error=switch",
"-Wno-parentheses",
"-std=c++14",
"-DHAVE_MAKE_UNIQUE",
"-DHAVE_TO_STRING",
],
includes = [
Expand Down
2 changes: 1 addition & 1 deletion cpp/src/ToxAv/lifecycle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ TOX_METHOD (jint, New,
tox4j_assert (toxav != nullptr);

// Create the master events object and set up our callbacks.
auto events = tox::callbacks<ToxAV> (std::make_unique<Events> ())
auto events = tox::callbacks<ToxAV> (make_unique<Events> ())
#define CALLBACK(NAME) .set<tox::callback_##NAME, tox4j_##NAME##_cb> ()
#include "tox/generated/av.h"
#undef CALLBACK
Expand Down
2 changes: 1 addition & 1 deletion cpp/src/ToxCore/lifecycle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ TOX_METHOD (jint, New,
tox4j_assert (tox != nullptr);

// Create the master events object and set up our callbacks.
auto events = tox::callbacks<Tox> (std::make_unique<Events> ())
auto events = tox::callbacks<Tox> (make_unique<Events> ())
#define CALLBACK(NAME) .set<tox::callback_##NAME, tox4j_##NAME##_cb> ()
#include "tox/generated/core.h"
#undef CALLBACK
Expand Down
17 changes: 9 additions & 8 deletions cpp/src/cpp14compat.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,17 @@
extern "C" char *gets (char *);
#endif

#if !defined(HAVE_MAKE_UNIQUE)
#include <memory>

namespace std {
template<typename T, typename ...Args>
unique_ptr<T>
make_unique (Args &&...args)
{
return std::unique_ptr<T> (new T (std::forward<Args> (args)...));
}
#if defined(HAVE_MAKE_UNIQUE)
using ::std::make_unique;
#else

template<typename T, typename ...Args>
std::unique_ptr<T>
make_unique (Args &&...args)
{
return std::unique_ptr<T> (new T (std::forward<Args> (args)...));
}
#endif

Expand Down
2 changes: 1 addition & 1 deletion cpp/src/util/debug_log.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ JniLog::Entry::~Entry ()


JniLog::JniLog ()
: self (std::make_unique<data> ())
: self (make_unique<data> ())
{
}

Expand Down
2 changes: 1 addition & 1 deletion cpp/test/util/wrap_void_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
static std::unique_ptr<int>
make_int (int i)
{
return std::make_unique<int> (i);
return make_unique<int> (i);
}


Expand Down

0 comments on commit 3060014

Please sign in to comment.