summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcus Müller <mmueller@gnuradio.org>2021-03-21 21:18:01 +0100
committerMarcus Müller <marcus@hostalia.de>2021-03-23 22:21:09 +0100
commit1a0be2e6b54496a8136a64d86e372ab219c6559b (patch)
tree1c580a1886146c45cdfe3b87621ee630c5e223b0
parentf40ce52d452f335d263d67c1711487ef700086aa (diff)
runtime/random: xoroshiro128p.h was _nearly_ C compatible
Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
-rw-r--r--gnuradio-runtime/include/gnuradio/xoroshiro128p.h4
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/random_python.cc2
2 files changed, 4 insertions, 2 deletions
diff --git a/gnuradio-runtime/include/gnuradio/xoroshiro128p.h b/gnuradio-runtime/include/gnuradio/xoroshiro128p.h
index 763c6386a9..f39a980e04 100644
--- a/gnuradio-runtime/include/gnuradio/xoroshiro128p.h
+++ b/gnuradio-runtime/include/gnuradio/xoroshiro128p.h
@@ -16,10 +16,12 @@
#ifndef INCLUDED_XOROSHIRO128P_H
#define INCLUDED_XOROSHIRO128P_H
#ifdef __cplusplus
+#include <cstdint>
extern "C" {
+#else
+#include <stdint.h>
#endif
-#include <cstdint>
/*! \brief rotating left shift helper
* According to the original authors, this will on most platforms reduce to a single
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/random_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/random_python.cc
index 82de4cc226..8c823e5977 100644
--- a/gnuradio-runtime/python/gnuradio/gr/bindings/random_python.cc
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/random_python.cc
@@ -35,7 +35,7 @@ void bind_random(py::module& m)
py::class_<random, std::shared_ptr<random>>(m, "random", D(random))
- .def(py::init<unsigned int, int, int>(),
+ .def(py::init<uint64_t, int64_t, int64_t>(),
py::arg("seed") = 0,
py::arg("min_integer") = 0,
py::arg("max_integer") = 2,