MCPcopy Create free account
hub / github.com/ada-url/ada / count_urlpattern_exec_invalid

Function count_urlpattern_exec_invalid

benchmarks/urlpattern.cpp:65–82  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

63}
64
65size_t count_urlpattern_exec_invalid() {
66 size_t how_many = 0;
67 auto pattern =
68 ada::parse_url_pattern<ada::url_pattern_regex::std_regex_provider>(
69 "https://*example.com/*");
70 if (!pattern) {
71 return std::size(url_examples);
72 }
73
74 for (const std::string& url_example : url_examples) {
75 auto result = pattern->exec(url_example);
76 if (!result) {
77 how_many++;
78 }
79 }
80
81 return how_many;
82}
83
84size_t count_urlpattern_test_invalid() {
85 size_t how_many = 0;

Callers 1

mainFunction · 0.85

Calls 1

execMethod · 0.80

Tested by

no test coverage detected