@@ -1189,8 +1189,26 @@ function gen_vm($def, $skel) {
1189
1189
// Insert header
1190
1190
out ($ f , $ GLOBALS ['header_text ' ]);
1191
1191
1192
+ out ($ f , "#ifdef ZEND_WIN32 \n" );
1192
1193
// Suppress free_op1 warnings on Windows
1193
- out ($ f , "#ifdef ZEND_WIN32 \n# pragma warning(once : 4101) \n#endif \n" );
1194
+ out ($ f , "# pragma warning(once : 4101) \n" );
1195
+ if (ZEND_VM_SPEC ) {
1196
+ // Suppress (<non-zero constant> || <expression>) warnings on windows
1197
+ out ($ f , "# pragma warning(once : 6235) \n" );
1198
+ // Suppress (<zero> && <expression>) warnings on windows
1199
+ out ($ f , "# pragma warning(once : 6237) \n" );
1200
+ // Suppress (<non-zero constant> && <expression>) warnings on windows
1201
+ out ($ f , "# pragma warning(once : 6239) \n" );
1202
+ // Suppress (<expression> && <non-zero constant>) warnings on windows
1203
+ out ($ f , "# pragma warning(once : 6240) \n" );
1204
+ // Suppress (<non-zero constant> || <non-zero constant>) warnings on windows
1205
+ out ($ f , "# pragma warning(once : 6285) \n" );
1206
+ // Suppress (<non-zero constant> || <expression>) warnings on windows
1207
+ out ($ f , "# pragma warning(once : 6286) \n" );
1208
+ // Suppress constant with constant comparsion warnings on windows
1209
+ out ($ f , "# pragma warning(once : 6326) \n" );
1210
+ }
1211
+ out ($ f , "#endif \n" );
1194
1212
1195
1213
// Support for ZEND_USER_OPCODE
1196
1214
out ($ f , "static user_opcode_handler_t zend_user_opcode_handlers[256] = { \n" );
0 commit comments