MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / normalize_string_handler

Function normalize_string_handler

internal/cbm/extract_calls.c:2995–3005  ·  view source on GitHub ↗

Extract second argument name (handler ref for route registrations). Normalize a string-form route handler to a resolvable handler name. * 'showUsers' → showUsers * 'UserController@show' → show (Laravel "Controller@method") * The method segment after '@' is the resolvable function/method name. */

Source from the content-addressed store, hash-verified

2993 * 'UserController@show' → show (Laravel "Controller@method")
2994 * The method segment after '@' is the resolvable function/method name. */
2995static const char *normalize_string_handler(CBMArena *a, const char *raw) {
2996 const char *unq = strip_quotes(a, raw);
2997 if (!unq || !unq[0]) {
2998 return NULL;
2999 }
3000 const char *at = strchr(unq, '@');
3001 if (at && at[1]) {
3002 return cbm_arena_strdup(a, at + 1);
3003 }
3004 return unq;
3005}
3006
3007/* True for a PHP class/namespace name: identifier segments joined by '\'. */
3008static bool php_is_class_path(const char *s) {

Callers 1

extract_handler_argFunction · 0.85

Calls 2

strip_quotesFunction · 0.70
cbm_arena_strdupFunction · 0.70

Tested by

no test coverage detected