I want to implement a simple template engine extension, which is being debugged recently. however, after the extension is compiled to so, the following situation occurs: when running make, the following warning occurs: {code ...} the code snippet is as follows: {code ...} at first I thought there was a problem with macro definition, but when I replaced Z_OBJ_P... I want to implement a simple template engine extension, which is being debugged recently. however, after the extension is compiled into so, the following situation occurs:
When running make, the following warning occurs:
/home/x64-debian-fxy/php5-5.4.4/ext/template_parser/template_parser.c: In function 'zif_template_parser_pause':/home/x64-debian-fxy/php5-5.4.4/ext/template_parser/template_parser.c:114:21: warning: assignment makes pointer from integer without a cast [enabled by default]
The code snippet is as follows:
// Fetch real object in order to fetch it's scope. if (Z_TYPE_P (object_container) = IS_OBJECT) {// The Problem Is going downstream. real_object = Z_OBJ_P (object_container);} else {real_object = NULL ;}
At first I thought there was a problem with macro definition, but when IZ_OBJ_PReplace with the expectedzend_object_get_addressWhen the header file is introducedphp.hIntroduction. I wonder if any of my predecessors who have the same experience have solved this problem. Please advise! Thank you!
Reply content:
I want to implement a simple template engine extension. Recently in debugging, the following situation occurs after the extension is compiled into so:
When running make, the following warning occurs:
/home/x64-debian-fxy/php5-5.4.4/ext/template_parser/template_parser.c: In function 'zif_template_parser_pause':/home/x64-debian-fxy/php5-5.4.4/ext/template_parser/template_parser.c:114:21: warning: assignment makes pointer from integer without a cast [enabled by default]
The code snippet is as follows:
// Fetch real object in order to fetch it's scope. if (Z_TYPE_P (object_container) = IS_OBJECT) {// The Problem Is going downstream. real_object = Z_OBJ_P (object_container);} else {real_object = NULL ;}
At first I thought there was a problem with macro definition, but when IZ_OBJ_PReplace with the expectedzend_object_get_addressWhen the header file is introducedphp.hIntroduction. I wonder if any of my predecessors who have the same experience have solved this problem. Please advise! Thank you!