We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0baa9ff commit 8d9e8d9Copy full SHA for 8d9e8d9
1 file changed
cpp2rust/converter/mapper.cpp
@@ -341,7 +341,8 @@ matchTemplate(const std::string &template_str,
341
// result = "Vec<i32>"
342
std::string instantiateTgt(const std::vector<std::string> &types,
343
const std::string &tgt_template) {
344
- assert(types.size() <= 9);
+ assert(types.size() <= TranslationRule::kMaxGenerics &&
345
+ "template placeholder exceeds kMaxGenerics");
346
std::string instantiated_template = tgt_template;
347
std::string::size_type pos = 0;
348
while ((pos = instantiated_template.find('T', pos)) != std::string::npos) {
0 commit comments