Modify the build process so that the VDBE opcode numbers and the table
that contains the opcode names are both automatically generated. This makes
it much easier to create new VDBE opcodes. (CVS 746)

FossilOrigin-Name: eb54d455b0325d3be96daf6c220c4ee3e0da1a85
diff --git a/src/expr.c b/src/expr.c
index 9a358c9..0aaaf0e 100644
--- a/src/expr.c
+++ b/src/expr.c
@@ -12,7 +12,7 @@
 ** This file contains routines used for analyzing expressions and
 ** for generating VDBE code that evaluates expressions in SQLite.
 **
-** $Id: expr.c,v 1.80 2002/08/24 18:24:54 drh Exp $
+** $Id: expr.c,v 1.81 2002/09/08 00:04:52 drh Exp $
 */
 #include "sqliteInt.h"
 #include <ctype.h>
@@ -1369,7 +1369,13 @@
     case TK_NE:
     case TK_EQ: {
       if( pParse->db->file_format>=4 && sqliteExprType(pExpr)==SQLITE_SO_TEXT ){
-        op += 6;  /* Convert numeric opcodes to text opcodes */
+        /* Convert numeric comparison opcodes into text comparison opcodes.
+        ** This step depends on the fact that the text comparision opcodes are
+        ** always 6 greater than their corresponding numeric comparison
+        ** opcodes.
+        */
+        assert( OP_Eq+6 == OP_StrEq );
+        op += 6;
       }
       sqliteExprCode(pParse, pExpr->pLeft);
       sqliteExprCode(pParse, pExpr->pRight);