View Issue Details

IDProjectCategoryView StatusLast Update
0001240OpenMPT[All Projects] libopenmptpublic2019-11-04 14:57
Reportermanx Assigned Tomanx  
PrioritynormalSeverityminorReproducibilityalways
Status assignedResolutionopen 
Product VersionOpenMPT 1.29.00.* (current testing) 
Target VersionOpenMPT 1.29 / libopenmpt 0.5 (goals)Fixed in Version 
Summary0001240: Modernize C++ API
Description

We should support more modern language features in the C++ API as appropriate:

C++11:

  • enum class for probe_file_header flags and result
  • enum class for module::render_param
  • enum class for module::command_index
  • inline namespace for API/ABI versioning (requires mirroring of the complete API though, might be worthwhile for 1.0 though)
  • constexpr library API version information (in addition to preprocessor)
  • maybe std::u16string and std::u32string for all APIs

C++14:

  • r12191: [[deprecated]] instead of compiler-specific attributes and macros

C++17:

  • r12301: std::byte buffer for module::module()

C++20:

  • std::span buffer for module::module()
  • std::span for module::read buffers
  • std::u8string for all strings
TagsNo tags attached.
Has the bug occurred in previous versions?
Tested code revision (in case you know it)

Relationships

related to 0001256 resolvedmanx require C++17 
related to 0001241 assignedmanx std::string_view for ctl key, and non-string overloads for ctl_get and ctl_set 

Activities

manx

manx

2019-09-05 13:39

administrator   ~0004040

If we want to support C++17 features in the libopenmpt API which I think we should for the next version), we either need to require C++17 also for building libopenmpt, or need to support multiple ABI-incompatible variants of the same libopenmpt version (which would be a nightmare).

manx

manx

2019-10-15 08:29

administrator  

libopenmpt-api-cpp17-byte-v1.patch (23,489 bytes)
Index: libopenmpt/dox/changelog.md
===================================================================
--- libopenmpt/dox/changelog.md	(revision 12200)
+++ libopenmpt/dox/changelog.md	(working copy)
@@ -9,6 +9,18 @@
 
  *  [**New**] OggMod compressed FastTracker 2 XM (OXM) modules are now
     supported.
+ *  [**New**] libopenmpt C++: New API
+    `openmpt::module::module(std::vector<std::byte> data)`,
+    `openmpt::module::module(const std::byte * data, std::size_t size)`,
+    `openmpt::module::module(const std::byte * beg, const std::byte * end)`.
+ *  [**New**] libopenmpt C++: New API
+    `openmpt::probe_file_header(flags, const std::byte * data, std::size_t size, filesize)`,
+    `openmpt::probe_file_header(flags, const std::byte * data, std::size_t size)`.
+ *  [**New**] libopenmpt_ext C++: New API
+    `openmpt::module_ext::module_ext(std::vector<std::byte> data)`,
+    `openmpt::module_ext::module_ext(const std::byte * data, std::size_t size)`,
+    `openmpt::module_ext::module_ext(std::vector<std::uint8_t> data)`,
+    `openmpt::module_ext::module_ext(const std::uint8_t * data, std::size_t size)`.
 
  *  [**Change**] std::istream based file I/O has been speed up.
 
Index: libopenmpt/libopenmpt.hpp
===================================================================
--- libopenmpt/libopenmpt.hpp	(revision 12192)
+++ libopenmpt/libopenmpt.hpp	(working copy)
@@ -19,6 +19,7 @@
 #include <string>
 #include <vector>
 
+#include <cstddef>
 #include <cstdint>
 
 /*!
@@ -294,6 +295,22 @@
   \retval probe_file_header_result_wantmoredata An answer could not be determined with the amount of data provided.
   \sa openmpt::probe_file_header_get_recommended_size()
   \sa openmpt::could_open_probability()
+  \since 0.5.0
+*/
+LIBOPENMPT_CXX_API int probe_file_header( std::uint64_t flags, const std::byte * data, std::size_t size, std::uint64_t filesize );
+//! Probe the provided bytes from the beginning of a file for supported file format headers to find out whether libopenmpt might be able to open it
+/*!
+  \param flags Ored mask of openmpt::probe_file_header_flags_modules and openmpt::probe_file_header_flags_containers, or openmpt::probe_file_header_flags_default.
+  \param data Beginning of the file data.
+  \param size Size of the beginning of the file data.
+  \param filesize Full size of the file data on disk.
+  \remarks It is recommended to provide openmpt::probe_file_header_get_recommended_size() bytes of data for data and size. If the file is smaller, only provide the filesize amount and set size and filesize to the file's size. 
+  \remarks openmpt::could_open_probability() provides a more elaborate interface that might be required for special use cases. It is recommended to use openmpt::probe_file_header() though, if possible.
+  \retval probe_file_header_result_success The file will most likely be supported by libopenmpt.
+  \retval probe_file_header_result_failure The file is not supported by libopenmpt.
+  \retval probe_file_header_result_wantmoredata An answer could not be determined with the amount of data provided.
+  \sa openmpt::probe_file_header_get_recommended_size()
+  \sa openmpt::could_open_probability()
   \since 0.3.0
 */
 LIBOPENMPT_CXX_API int probe_file_header( std::uint64_t flags, const std::uint8_t * data, std::size_t size, std::uint64_t filesize );
@@ -311,6 +328,22 @@
   \retval probe_file_header_result_wantmoredata An answer could not be determined with the amount of data provided.
   \sa openmpt::probe_file_header_get_recommended_size()
   \sa openmpt::could_open_probability()
+  \since 0.5.0
+*/
+LIBOPENMPT_CXX_API int probe_file_header( std::uint64_t flags, const std::byte * data, std::size_t size );
+//! Probe the provided bytes from the beginning of a file for supported file format headers to find out whether libopenmpt might be able to open it
+/*!
+  \param flags Ored mask of openmpt::probe_file_header_flags_modules and openmpt::probe_file_header_flags_containers, or openmpt::probe_file_header_flags_default.
+  \param data Beginning of the file data.
+  \param size Size of the beginning of the file data.
+  \remarks It is recommended to use the overload of this function that also takes the filesize as parameter if at all possile. libopenmpt can provide more accurate answers if the filesize is known.
+  \remarks It is recommended to provide openmpt::probe_file_header_get_recommended_size() bytes of data for data and size. If the file is smaller, only provide the filesize amount and set size to the file's size. 
+  \remarks openmpt::could_open_probability() provides a more elaborate interface that might be required for special use cases. It is recommended to use openmpt::probe_file_header() though, if possible.
+  \retval probe_file_header_result_success The file will most likely be supported by libopenmpt.
+  \retval probe_file_header_result_failure The file is not supported by libopenmpt.
+  \retval probe_file_header_result_wantmoredata An answer could not be determined with the amount of data provided.
+  \sa openmpt::probe_file_header_get_recommended_size()
+  \sa openmpt::could_open_probability()
   \since 0.3.0
 */
 LIBOPENMPT_CXX_API int probe_file_header( std::uint64_t flags, const std::uint8_t * data, std::size_t size );
@@ -424,7 +457,39 @@
 	  \throws openmpt::exception Throws an exception derived from openmpt::exception in case the provided file cannot be opened.
 	  \remarks The input data can be discarded after an openmpt::module has been constructed successfully.
 	  \sa \ref libopenmpt_cpp_fileio
+	  \since 0.5.0
 	*/
+	module( const std::vector<std::byte> & data, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
+	/*!
+	  \param beg Begin of data to load the module from.
+	  \param end End of data to load the module from.
+	  \param log Log where any warnings or errors are printed to. The lifetime of the reference has to be as long as the lifetime of the module instance.
+	  \param ctls A map of initial ctl values, see openmpt::module::get_ctls.
+	  \throws openmpt::exception Throws an exception derived from openmpt::exception in case the provided file cannot be opened.
+	  \remarks The input data can be discarded after an openmpt::module has been constructed successfully.
+	  \sa \ref libopenmpt_cpp_fileio
+	  \since 0.5.0
+	*/
+	module( const std::byte * beg, const std::byte * end, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
+	/*!
+	  \param data Data to load the module from.
+	  \param size Amount of data available.
+	  \param log Log where any warnings or errors are printed to. The lifetime of the reference has to be as long as the lifetime of the module instance.
+	  \param ctls A map of initial ctl values, see openmpt::module::get_ctls.
+	  \throws openmpt::exception Throws an exception derived from openmpt::exception in case the provided file cannot be opened.
+	  \remarks The input data can be discarded after an openmpt::module has been constructed successfully.
+	  \sa \ref libopenmpt_cpp_fileio
+	  \since 0.5.0
+	*/
+	module( const std::byte * data, std::size_t size, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
+	/*!
+	  \param data Data to load the module from.
+	  \param log Log where any warnings or errors are printed to. The lifetime of the reference has to be as long as the lifetime of the module instance.
+	  \param ctls A map of initial ctl values, see openmpt::module::get_ctls.
+	  \throws openmpt::exception Throws an exception derived from openmpt::exception in case the provided file cannot be opened.
+	  \remarks The input data can be discarded after an openmpt::module has been constructed successfully.
+	  \sa \ref libopenmpt_cpp_fileio
+	*/
 	module( const std::vector<std::uint8_t> & data, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
 	/*!
 	  \param beg Begin of data to load the module from.
Index: libopenmpt/libopenmpt_cxx.cpp
===================================================================
--- libopenmpt/libopenmpt_cxx.cpp	(revision 12192)
+++ libopenmpt/libopenmpt_cxx.cpp	(working copy)
@@ -137,9 +137,15 @@
 std::size_t probe_file_header_get_recommended_size() {
 	return openmpt::module_impl::probe_file_header_get_recommended_size();
 }
+int probe_file_header( std::uint64_t flags, const std::byte * data, std::size_t size, std::uint64_t filesize ) {
+	return openmpt::module_impl::probe_file_header( flags, data, size, filesize );
+}
 int probe_file_header( std::uint64_t flags, const std::uint8_t * data, std::size_t size, std::uint64_t filesize ) {
 	return openmpt::module_impl::probe_file_header( flags, data, size, filesize );
 }
+int probe_file_header( std::uint64_t flags, const std::byte * data, std::size_t size ) {
+	return openmpt::module_impl::probe_file_header( flags, data, size );
+}
 int probe_file_header( std::uint64_t flags, const std::uint8_t * data, std::size_t size ) {
 	return openmpt::module_impl::probe_file_header( flags, data, size );
 }
@@ -177,6 +183,18 @@
 	impl = new module_impl( stream, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
 }
 
+module::module( const std::vector<std::byte> & data, std::ostream & log, const std::map< std::string, std::string > & ctls ) : impl(0) {
+	impl = new module_impl( data, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
+}
+
+module::module( const std::byte * beg, const std::byte * end, std::ostream & log, const std::map< std::string, std::string > & ctls ) : impl(0) {
+	impl = new module_impl( beg, end - beg, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
+}
+
+module::module( const std::byte * data, std::size_t size, std::ostream & log, const std::map< std::string, std::string > & ctls ) : impl(0) {
+	impl = new module_impl( data, size, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
+}
+
 module::module( const std::vector<std::uint8_t> & data, std::ostream & log, const std::map< std::string, std::string > & ctls ) : impl(0) {
 	impl = new module_impl( data, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
 }
@@ -396,14 +414,30 @@
 	ext_impl = new module_ext_impl( stream, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
 	set_impl( ext_impl );
 }
+module_ext::module_ext( const std::vector<std::uint8_t> & data, std::ostream & log, const std::map< std::string, std::string > & ctls ) : ext_impl(0) {
+	ext_impl = new module_ext_impl( data, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
+	set_impl( ext_impl );
+}
 module_ext::module_ext( const std::vector<char> & data, std::ostream & log, const std::map< std::string, std::string > & ctls ) : ext_impl(0) {
 	ext_impl = new module_ext_impl( data, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
 	set_impl( ext_impl );
 }
+module_ext::module_ext( const std::vector<std::byte> & data, std::ostream & log, const std::map< std::string, std::string > & ctls ) : ext_impl(0) {
+	ext_impl = new module_ext_impl( data, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
+	set_impl( ext_impl );
+}
+module_ext::module_ext( const std::uint8_t * data, std::size_t size, std::ostream & log, const std::map< std::string, std::string > & ctls ) : ext_impl(0) {
+	ext_impl = new module_ext_impl( data, size, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
+	set_impl( ext_impl );
+}
 module_ext::module_ext( const char * data, std::size_t size, std::ostream & log, const std::map< std::string, std::string > & ctls ) : ext_impl(0) {
 	ext_impl = new module_ext_impl( data, size, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
 	set_impl( ext_impl );
 }
+module_ext::module_ext( const std::byte * data, std::size_t size, std::ostream & log, const std::map< std::string, std::string > & ctls ) : ext_impl(0) {
+	ext_impl = new module_ext_impl( data, size, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
+	set_impl( ext_impl );
+}
 module_ext::module_ext( const void * data, std::size_t size, std::ostream & log, const std::map< std::string, std::string > & ctls ) : ext_impl(0) {
 	ext_impl = new module_ext_impl( data, size, openmpt::helper::make_unique<std_ostream_log>( log ), ctls );
 	set_impl( ext_impl );
Index: libopenmpt/libopenmpt_ext.hpp
===================================================================
--- libopenmpt/libopenmpt_ext.hpp	(revision 12192)
+++ libopenmpt/libopenmpt_ext.hpp	(working copy)
@@ -44,7 +44,11 @@
 	void operator = ( const module_ext & );
 public:
 	module_ext( std::istream & stream, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
+	module_ext( const std::vector<std::byte> & data, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
+	module_ext( const std::vector<std::uint8_t> & data, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
 	module_ext( const std::vector<char> & data, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
+	module_ext( const std::byte * data, std::size_t size, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
+	module_ext( const std::uint8_t * data, std::size_t size, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
 	module_ext( const char * data, std::size_t size, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
 	module_ext( const void * data, std::size_t size, std::ostream & log = std::clog, const std::map< std::string, std::string > & ctls = detail::initial_ctls_map() );
 	virtual ~module_ext();
Index: libopenmpt/libopenmpt_ext_impl.cpp
===================================================================
--- libopenmpt/libopenmpt_ext_impl.cpp	(revision 12192)
+++ libopenmpt/libopenmpt_ext_impl.cpp	(working copy)
@@ -28,6 +28,9 @@
 	module_ext_impl::module_ext_impl( std::istream & stream, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls ) : module_impl( stream, std::move(log), ctls ) {
 		ctor();
 	}
+	module_ext_impl::module_ext_impl( const std::vector<std::byte> & data, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls ) : module_impl( data, std::move(log), ctls ) {
+		ctor();
+	}
 	module_ext_impl::module_ext_impl( const std::vector<std::uint8_t> & data, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls ) : module_impl( data, std::move(log), ctls ) {
 		ctor();
 	}
@@ -34,6 +37,9 @@
 	module_ext_impl::module_ext_impl( const std::vector<char> & data, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls ) : module_impl( data, std::move(log), ctls ) {
 		ctor();
 	}
+	module_ext_impl::module_ext_impl( const std::byte * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls ) : module_impl( data, size, std::move(log), ctls ) {
+		ctor();
+	}
 	module_ext_impl::module_ext_impl( const std::uint8_t * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls ) : module_impl( data, size, std::move(log), ctls ) {
 		ctor();
 	}
Index: libopenmpt/libopenmpt_ext_impl.hpp
===================================================================
--- libopenmpt/libopenmpt_ext_impl.hpp	(revision 12192)
+++ libopenmpt/libopenmpt_ext_impl.hpp	(working copy)
@@ -33,8 +33,10 @@
 public:
 	module_ext_impl( callback_stream_wrapper stream, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_ext_impl( std::istream & stream, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
+	module_ext_impl( const std::vector<std::byte> & data, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_ext_impl( const std::vector<std::uint8_t> & data, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_ext_impl( const std::vector<char> & data, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
+	module_ext_impl( const std::byte * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_ext_impl( const std::uint8_t * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_ext_impl( const char * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_ext_impl( const void * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
Index: libopenmpt/libopenmpt_impl.cpp
===================================================================
--- libopenmpt/libopenmpt_impl.cpp	(revision 12192)
+++ libopenmpt/libopenmpt_impl.cpp	(working copy)
@@ -669,6 +669,24 @@
 std::size_t module_impl::probe_file_header_get_recommended_size() {
 	return CSoundFile::ProbeRecommendedSize;
 }
+int module_impl::probe_file_header( std::uint64_t flags, const std::byte * data, std::size_t size, std::uint64_t filesize ) {
+	int result = 0;
+	switch ( CSoundFile::Probe( static_cast<CSoundFile::ProbeFlags>( flags ), mpt::span<const std::byte>( data, size ), &filesize ) ) {
+		case CSoundFile::ProbeSuccess:
+			result = probe_file_header_result_success;
+			break;
+		case CSoundFile::ProbeFailure:
+			result = probe_file_header_result_failure;
+			break;
+		case CSoundFile::ProbeWantMoreData:
+			result = probe_file_header_result_wantmoredata;
+			break;
+		default:
+			throw exception("internal error");
+			break;
+	}
+	return result;
+}
 int module_impl::probe_file_header( std::uint64_t flags, const std::uint8_t * data, std::size_t size, std::uint64_t filesize ) {
 	int result = 0;
 	switch ( CSoundFile::Probe( static_cast<CSoundFile::ProbeFlags>( flags ), mpt::span<const std::byte>( mpt::byte_cast<const std::byte*>( data ), size ), &filesize ) ) {
@@ -705,6 +723,24 @@
 	}
 	return result;
 }
+int module_impl::probe_file_header( std::uint64_t flags, const std::byte * data, std::size_t size ) {
+	int result = 0;
+	switch ( CSoundFile::Probe( static_cast<CSoundFile::ProbeFlags>( flags ), mpt::span<const std::byte>( data, size ), nullptr ) ) {
+		case CSoundFile::ProbeSuccess:
+			result = probe_file_header_result_success;
+			break;
+		case CSoundFile::ProbeFailure:
+			result = probe_file_header_result_failure;
+			break;
+		case CSoundFile::ProbeWantMoreData:
+			result = probe_file_header_result_wantmoredata;
+			break;
+		default:
+			throw exception("internal error");
+			break;
+	}
+	return result;
+}
 int module_impl::probe_file_header( std::uint64_t flags, const std::uint8_t * data, std::size_t size ) {
 	int result = 0;
 	switch ( CSoundFile::Probe( static_cast<CSoundFile::ProbeFlags>( flags ), mpt::span<const std::byte>( mpt::byte_cast<const std::byte*>( data ), size ), nullptr ) ) {
@@ -838,6 +874,11 @@
 	load( make_FileReader( &stream ), ctls );
 	apply_libopenmpt_defaults();
 }
+module_impl::module_impl( const std::vector<std::byte> & data, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls ) : m_Log(std::move(log)) {
+	ctor( ctls );
+	load( make_FileReader( mpt::as_span( data ) ), ctls );
+	apply_libopenmpt_defaults();
+}
 module_impl::module_impl( const std::vector<std::uint8_t> & data, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls ) : m_Log(std::move(log)) {
 	ctor( ctls );
 	load( make_FileReader( mpt::as_span( data ) ), ctls );
@@ -848,6 +889,11 @@
 	load( make_FileReader( mpt::byte_cast< mpt::span< const std::byte > >( mpt::as_span( data ) ) ), ctls );
 	apply_libopenmpt_defaults();
 }
+module_impl::module_impl( const std::byte * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls ) : m_Log(std::move(log)) {
+	ctor( ctls );
+	load( make_FileReader( mpt::as_span( data, size ) ), ctls );
+	apply_libopenmpt_defaults();
+}
 module_impl::module_impl( const std::uint8_t * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls ) : m_Log(std::move(log)) {
 	ctor( ctls );
 	load( make_FileReader( mpt::as_span( data, size ) ), ctls );
Index: libopenmpt/libopenmpt_impl.hpp
===================================================================
--- libopenmpt/libopenmpt_impl.hpp	(revision 12192)
+++ libopenmpt/libopenmpt_impl.hpp	(working copy)
@@ -135,8 +135,10 @@
 	static double could_open_probability( callback_stream_wrapper stream, double effort, std::unique_ptr<log_interface> log );
 	static double could_open_probability( std::istream & stream, double effort, std::unique_ptr<log_interface> log );
 	static std::size_t probe_file_header_get_recommended_size();
+	static int probe_file_header( std::uint64_t flags, const std::byte * data, std::size_t size, std::uint64_t filesize );
 	static int probe_file_header( std::uint64_t flags, const std::uint8_t * data, std::size_t size, std::uint64_t filesize );
 	static int probe_file_header( std::uint64_t flags, const void * data, std::size_t size, std::uint64_t filesize );
+	static int probe_file_header( std::uint64_t flags, const std::byte * data, std::size_t size );
 	static int probe_file_header( std::uint64_t flags, const std::uint8_t * data, std::size_t size );
 	static int probe_file_header( std::uint64_t flags, const void * data, std::size_t size );
 	static int probe_file_header( std::uint64_t flags, std::istream & stream );
@@ -143,8 +145,10 @@
 	static int probe_file_header( std::uint64_t flags, callback_stream_wrapper stream );
 	module_impl( callback_stream_wrapper stream, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_impl( std::istream & stream, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
+	module_impl( const std::vector<std::byte> & data, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_impl( const std::vector<std::uint8_t> & data, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_impl( const std::vector<char> & data, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
+	module_impl( const std::byte * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_impl( const std::uint8_t * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_impl( const char * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
 	module_impl( const void * data, std::size_t size, std::unique_ptr<log_interface> log, const std::map< std::string, std::string > & ctls );
Saga Musix

Saga Musix

2019-10-26 15:47

administrator   ~0004118

libopenmpt-api-cpp17-byte-v1 looks good in general, but I would suggest that we change "Ored mask" to "Or-ed mask" or "Bit mask" in the doxygen comments. It took me a few seconds to parse what the word was supposed to mean.

manx

manx

2019-11-04 14:52

administrator   ~0004139

I would suggest that we change "Ored mask" to "Or-ed mask" or "Bit mask" in the doxygen comments

r12300

Issue History

Date Modified Username Field Change
2019-07-29 20:23 manx New Issue
2019-07-29 20:23 manx Status new => assigned
2019-07-29 20:23 manx Assigned To => manx
2019-07-29 20:47 manx Relationship added related to 0001241
2019-09-05 13:10 manx Relationship added related to 0001256
2019-09-05 13:39 manx Note Added: 0004040
2019-10-03 08:32 manx Description Updated View Revisions
2019-10-03 08:36 manx Description Updated View Revisions
2019-10-14 17:55 manx File Added: libopenmpt-api-cpp17-v1.patch
2019-10-14 18:23 manx File Added: libopenmpt-api-cpp17-v3.patch
2019-10-14 18:26 manx Description Updated View Revisions
2019-10-14 18:27 manx File Deleted: libopenmpt-api-cpp17-v1.patch
2019-10-14 18:27 manx File Deleted: libopenmpt-api-cpp17-v3.patch
2019-10-15 08:29 manx File Added: libopenmpt-api-cpp17-byte-v1.patch
2019-10-26 15:47 Saga Musix Note Added: 0004118
2019-11-04 14:52 manx Note Added: 0004139
2019-11-04 14:57 manx Description Updated View Revisions