1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-12 13:01:09 +03:00

Change an unreachable testcase() into an assert()

FossilOrigin-Name: 062e00c4d7e30155299339eaefe6cbe01953894baebf0af6d7ab3295b7436eb7
This commit is contained in:
drh
2019-12-18 21:22:40 +00:00
parent 396afe6f6a
commit c29af653e6
3 changed files with 12 additions and 8 deletions

View File

@@ -3709,7 +3709,11 @@ expr_code_doover:
return target;
}
default: {
testcase( op!=TK_NULL );
/* Make NULL the default case so that if a bug causes an illegal
** Expr node to be passed into this function, it will be handled
** sanely and not crash. But keep an assert() to bring the problem
** to the attention of the developers. */
assert( op==TK_NULL );
sqlite3VdbeAddOp2(v, OP_Null, 0, target);
return target;
}