History

Ensure a C++ object exists for all static const members of structs or create constexpr functions. - This is an attempt to adhere to the letter of the C++ specification.

arr committed 9 years ago

Commit af5c7a91 parent 4d839d714 files · +86 −64Browse files

Showing the changes to src/vm/module_reader.cpp (1 of 14 files). Show all

Unified · Split

src/vm/module_reader.cpp+7−7
@@ -25,14 +25,14 @@ using namespace disvm::format; · 24 unmodified lines
2525 namespace
2626 {
2727 // constants used in module processing
28− struct module_constants
28+ namespace module_constants
2929 {
30− static const auto max_type_pointer_count = operand_t{ 128 * 1024 };
31− static const auto no_error_handle_type_desc = operand_t{ -1 };
32− static const auto no_entry_pc = vm_pc_t{ -1 };
33− static const auto vm_module_type_desc_number = std::size_t{ 0 };
34− static const auto max_module_name_bytes = std::size_t{ 128 }; // Including null
35− static const auto array_address_stack_size = std::size_t{ 4 };
30+ const auto max_type_pointer_count = operand_t{ 128 * 1024 };
31+ const auto no_error_handle_type_desc = operand_t{ -1 };
32+ const auto no_entry_pc = vm_pc_t{ -1 };
33+ const auto vm_module_type_desc_number = std::size_t{ 0 };
34+ const auto max_module_name_bytes = std::size_t{ 128 }; // Including null
35+ const auto array_address_stack_size = std::size_t{ 4 };
3636 };
3737
3838 // enumeration for types in the data section