_njs_object_proto_lookup(njs_object_t *proto, njs_value_type_t type)
{
    do {
        if (njs_fast_path(proto->type == type)) {
            break;
        }

        proto = proto->__proto__;
    } while (proto != NULL);

    return proto;
}
_njs_object_proto_lookup(njs_object_t *proto, njs_value_type_t type)
{
    do {
        if (njs_fast_path(proto->type == type)) {
            break;
        }

        proto = proto->__proto__;
    } while (proto != NULL);

    return proto;
}