From: trevor_hansen Date: Tue, 11 Aug 2009 07:02:50 +0000 (+0000) Subject: Improve type checking for BVZX & BVSX. X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=fcff324584cbcbee7d6c6cc048d7b2b46c4fa8b4;p=francis%2Fstp.git Improve type checking for BVZX & BVSX. git-svn-id: https://stp-fast-prover.svn.sourceforge.net/svnroot/stp-fast-prover/trunk/stp@103 e59a4935-1847-0410-ae03-e826735625c1 --- diff --git a/AST/AST.cpp b/AST/AST.cpp index 7f44c35..509880e 100644 --- a/AST/AST.cpp +++ b/AST/AST.cpp @@ -1365,6 +1365,8 @@ bool BeevMgr::BVTypeCheck(const ASTNode& n) { FatalError("BVTypeCheck: BVSX(t,bvsx_len) : length of 't' must be <= bvsx_len\n", n); } + if ((v.size() != 2)) + FatalError("BVTypeCheck:BVSX must have two arguments. The second is the new width\n", n); break; case BVZX: @@ -1374,6 +1376,9 @@ bool BeevMgr::BVTypeCheck(const ASTNode& n) { FatalError("BVTypeCheck: BVZX(t,bvzx_len) : length of 't' must be <= bvzx_len\n", n); } + if ((v.size() != 2)) + FatalError("BVTypeCheck:BVZX must have two arguments. The second is the new width\n", n); + break; default: