laruence / yaf

Fast php framework written in c, built in php extension
http://pecl.php.net/package/yaf
Other
4.52k stars 1.37k forks source link

Fix build #564

Closed twose closed 2 years ago

twose commented 2 years ago
/path/to/yaf/views/yaf_view_simple.c:415:63: error: too few arguments to function call, expected 3, have 2
        op_array = zend_compile_string(Z_STR(phtml), eval_desc);

/path/to/yaf/yaf.c:603:7: warning: expression result unused [-Wunused-value]
        for (idx; idx < sizeof(yaf_known_chars)/sizeof(char*) - 1; idx++) {

/path/to/yaf/yaf.c:53:12: warning: duplicate 'const' declaration specifier [-Wduplicate-decl-specifier]
const char const *yaf_known_chars[] = {

./php_yaf.h:157:19: warning: duplicate 'const' declaration specifier [-Wduplicate-decl-specifier]
extern const char const *yaf_known_chars[];

/path/to/yaf/routes/yaf_route_map.c:134:43: warning: passing 'unsigned char *' to parameter of type 'const char *' converts between pointers to integer types with different sign [-Wpointer-sign]
                zend_str_tolower_copy(ZSTR_VAL(result), str, end - str);

/path/to/yaf/yaf_dispatcher.c:826:1: warning: non-void function does not return a value in all control paths [-Wreturn-type]
}

/path/to/yaf/routes/yaf_route_map.c:134:43: warning: passing 'unsigned char *' to parameter of type 'const char *' converts between pointers to integer types with different sign [-Wpointer-sign]
                zend_str_tolower_copy(ZSTR_VAL(result), str, end - str);

/path/to/yaf/routes/yaf_route_map.c:141:4: warning: expression result unused [-Wunused-value]
                        *p++, *q++;
                        ^~~~
/path/to/yaf/routes/yaf_route_map.c:141:10: warning: expression result unused [-Wunused-value]
                        *p++, *q++;
Warning: Yaf_Response_Abstract::__toString() implemented without string return type in Unknown on line 0
laruence commented 2 years ago

现在改成用stub.php来做arginfo了,所以这个PR就暂时没法接受了哈,不过还是非常感谢:)