File tree 1 file changed +6
-6
lines changed
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -45,9 +45,14 @@ struct Module
45
45
// Types of globals defined in import section
46
46
std::vector<GlobalType> imported_global_types;
47
47
48
+ size_t get_function_count () const noexcept
49
+ {
50
+ return imported_function_types.size () + funcsec.size ();
51
+ }
52
+
48
53
const FuncType& get_function_type (FuncIdx idx) const noexcept
49
54
{
50
- assert (idx < imported_function_types. size () + funcsec. size ());
55
+ assert (idx < get_function_count ());
51
56
52
57
if (idx < imported_function_types.size ())
53
58
return imported_function_types[idx];
@@ -58,11 +63,6 @@ struct Module
58
63
return typesec[type_idx];
59
64
}
60
65
61
- size_t get_function_count () const noexcept
62
- {
63
- return imported_function_types.size () + funcsec.size ();
64
- }
65
-
66
66
size_t get_global_count () const noexcept
67
67
{
68
68
return imported_global_types.size () + globalsec.size ();
You can’t perform that action at this time.
0 commit comments