cvs: ZendEngine2 / zend_compile.c

From: Date: Wed, 14 Jan 2004 14:00:12 +0000
Subject: cvs: ZendEngine2 / zend_compile.c
Groups: php.zend-engine.cvs 
Request: Send a blank email to php-zend-engine-cvs+get-2211@lists.php.net to get a copy of this message
zeev Wed Jan 14 09:00:12 2004 EDT Modified files: /ZendEngine2 zend_compile.c Log: Don't allow interfaces to implement anything Index: ZendEngine2/zend_compile.c diff -u ZendEngine2/zend_compile.c:1.513 ZendEngine2/zend_compile.c:1.514 --- ZendEngine2/zend_compile.c:1.513 Mon Jan 12 02:15:55 2004 +++ ZendEngine2/zend_compile.c Wed Jan 14 09:00:11 2004 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: zend_compile.c,v 1.513 2004/01/12 07:15:55 andi Exp $ */ +/* $Id: zend_compile.c,v 1.514 2004/01/14 14:00:11 zeev Exp $ */ #include "zend_language_parser.h" #include "zend.h" @@ -2420,6 +2420,10 @@ { zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); + if (CG(active_class_entry)->ce_flags & ZEND_ACC_INTERFACE) { + zend_error(E_COMPILE_ERROR, "Interfaces cannot implement other classes/interfaces"); + } + opline->opcode = ZEND_ADD_INTERFACE; opline->op1 = CG(implementing_class); opline->op2 = *interface_znode;

« previous php.zend-engine.cvs (#2211) next »