Skip to content

Commit

Permalink
Merge pull request #226 from JohanMabille/new_server
Browse files Browse the repository at this point in the history
Upgraded to xeus 2.0.0
  • Loading branch information
JohanMabille committed Sep 14, 2021
2 parents cbdc377 + 4ea3128 commit 53e776f
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ install:
- conda update -q conda
- conda info -a
# Install host dependencies
- conda install xeus=1.0.0 cppzmq xproperty=0.11.0 nlohmann_json -c conda-forge
- conda install xeus=2.0.0 cppzmq xproperty=0.11.0 nlohmann_json=3.9.1 -c conda-forge
# Install build dependencies
- conda install cmake -c conda-forge
- cmake -G "NMake Makefiles" -D CMAKE_BUILD_TYPE=Release -D CMAKE_INSTALL_PREFIX=%MINICONDA%\\LIBRARY -DDOWNLOAD_GTEST=ON .
Expand Down
4 changes: 2 additions & 2 deletions environment-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ dependencies:
# Build dependencies
- cmake
# Host dependencies
- xeus=1.0.0
- xeus=2.0.0
- cppzmq
- xproperty=0.11.0
- nlohmann_json
- nlohmann_json=3.9.1
3 changes: 1 addition & 2 deletions include/xwidgets/xaudio.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,7 @@ namespace xw
using value_type = typename decltype(audio::value)::value_type;
std::size_t index = buffer_index(patch[property.name()].template get<std::string>());
const auto& value_buffer = buffers[index];
const char* value_buf = value_buffer.data<const char>();
property = value_type(value_buf, value_buf + value_buffer.size());
property = value_type(value_buffer.data(), value_buffer.data() + value_buffer.size());
}
}

Expand Down
2 changes: 1 addition & 1 deletion include/xwidgets/xcommon.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ namespace xw
inline void xwidgets_serialize(const std::vector<char>& value, nl::json& j, xeus::buffer_sequence& buffers)
{
j = xbuffer_reference_prefix() + std::to_string(buffers.size());
buffers.emplace_back(value.data(), value.size());
buffers.push_back(value);
}

template <class T>
Expand Down
3 changes: 1 addition & 2 deletions include/xwidgets/ximage.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,7 @@ namespace xw
using value_type = typename decltype(image::value)::value_type;
std::size_t index = buffer_index(patch[property.name()].template get<std::string>());
const auto& value_buffer = buffers[index];
const char* value_buf = value_buffer.data<const char>();
property = value_type(value_buf, value_buf + value_buffer.size());
property = value_type(value_buffer.data(), value_buffer.data() + value_buffer.size());
}
}

Expand Down
3 changes: 1 addition & 2 deletions include/xwidgets/xvideo.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,7 @@ namespace xw
using value_type = typename decltype(video::value)::value_type;
std::size_t index = buffer_index(patch[property.name()].template get<std::string>());
const auto& value_buffer = buffers[index];
const char* value_buf = value_buffer.data<const char>();
property = value_type(value_buf, value_buf + value_buffer.size());
property = value_type(value_buffer.data(), value_buffer.data() + value_buffer.size());
}
}

Expand Down
2 changes: 2 additions & 0 deletions src/xbinary.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
* The full license is in the file LICENSE, distributed with this software. *
****************************************************************************/

#include <sstream>

#include "xwidgets/xbinary.hpp"

namespace nl = nlohmann;
Expand Down

0 comments on commit 53e776f

Please sign in to comment.