Some compilers do not accept the not symbol.

This commit is contained in:
steve 2000-02-23 04:43:43 +00:00
parent 5aea537ab9
commit 843af31958
5 changed files with 35 additions and 18 deletions

View File

@ -17,7 +17,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*/
#if !defined(WINNT) && !defined(macintosh)
#ident "$Id: verinum.cc,v 1.15 2000/02/23 02:56:56 steve Exp $"
#ident "$Id: verinum.cc,v 1.16 2000/02/23 04:43:43 steve Exp $"
#endif
# include "verinum.h"
@ -395,7 +395,7 @@ static verinum::V add_with_carry(verinum::V l, verinum::V r, verinum::V&c)
return verinum::V0;
}
verinum not(const verinum&left)
verinum v_not(const verinum&left)
{
verinum val = left;
for (unsigned idx = 0 ; idx < val.len() ; idx += 1)
@ -445,7 +445,7 @@ verinum operator + (const verinum&left, const verinum&right)
verinum operator - (const verinum&left, const verinum&r)
{
verinum right = not(r);
verinum right = v_not(r);
unsigned min = left.len();
if (right.len() < min) min = right.len();
@ -471,6 +471,9 @@ verinum operator - (const verinum&left, const verinum&r)
/*
* $Log: verinum.cc,v $
* Revision 1.16 2000/02/23 04:43:43 steve
* Some compilers do not accept the not symbol.
*
* Revision 1.15 2000/02/23 02:56:56 steve
* Macintosh compilers do not support ident.
*

View File

@ -19,7 +19,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*/
#if !defined(WINNT) && !defined(macintosh)
#ident "$Id: verinum.h,v 1.10 2000/02/23 02:56:56 steve Exp $"
#ident "$Id: verinum.h,v 1.11 2000/02/23 04:43:43 steve Exp $"
#endif
# include <string>
@ -102,8 +102,13 @@ extern verinum::V operator <= (const verinum&left, const verinum&right);
extern verinum operator + (const verinum&left, const verinum&right);
extern verinum operator - (const verinum&left, const verinum&right);
extern verinum v_not(const verinum&left);
/*
* $Log: verinum.h,v $
* Revision 1.11 2000/02/23 04:43:43 steve
* Some compilers do not accept the not symbol.
*
* Revision 1.10 2000/02/23 02:56:56 steve
* Macintosh compilers do not support ident.
*

View File

@ -19,7 +19,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*/
#if !defined(WINNT) && !defined(macintosh)
#ident "$Id: vvm.h,v 1.30 2000/02/23 02:56:56 steve Exp $"
#ident "$Id: vvm.h,v 1.31 2000/02/23 04:43:43 steve Exp $"
#endif
# include <cassert>
@ -83,7 +83,7 @@ inline vpip_bit_t greater_with_cascade(vpip_bit_t l, vpip_bit_t r, vpip_bit_t c)
extern vpip_bit_t add_with_carry(vpip_bit_t l, vpip_bit_t r, vpip_bit_t&carry);
inline vpip_bit_t not(vpip_bit_t l)
inline vpip_bit_t v_not(vpip_bit_t l)
{
switch (l) {
case V0:
@ -276,6 +276,9 @@ class vvm_memory_t : public __vpiMemory {
/*
* $Log: vvm.h,v $
* Revision 1.31 2000/02/23 04:43:43 steve
* Some compilers do not accept the not symbol.
*
* Revision 1.30 2000/02/23 02:56:56 steve
* Macintosh compilers do not support ident.
*

View File

@ -19,7 +19,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*/
#if !defined(WINNT) && !defined(macintosh)
#ident "$Id: vvm_func.h,v 1.19 2000/02/23 02:56:56 steve Exp $"
#ident "$Id: vvm_func.h,v 1.20 2000/02/23 04:43:43 steve Exp $"
#endif
# include "vvm.h"
@ -103,7 +103,7 @@ vvm_bitset_t<1> vvm_unop_xor(const vvm_bitset_t<WIDTH>&r)
for (unsigned idx = 0 ; idx < WIDTH ; idx += 1) {
if (r[idx] == V1)
res[0] = not(res[0]);
res[0] = v_not(res[0]);
}
return res;
@ -112,7 +112,7 @@ vvm_bitset_t<1> vvm_unop_xor(const vvm_bitset_t<WIDTH>&r)
template <unsigned WIDTH>
vvm_bitset_t<1> vvm_unop_xnor(const vvm_bitset_t<WIDTH>&r)
{
return not(vvm_unop_xor(r));
return v_not(vvm_unop_xor(r));
}
//
@ -166,7 +166,7 @@ vvm_bitset_t<WIDTH> vvm_binop_nor(const vvm_bitset_t<WIDTH>&l,
{
vvm_bitset_t<WIDTH> result;
for (unsigned idx = 0 ; idx < WIDTH ; idx += 1)
result[idx] = not(l[idx] | r[idx]);
result[idx] = v_not(l[idx] | r[idx]);
return result;
}
@ -245,7 +245,7 @@ vvm_bitset_t<WIDTH> vvm_binop_xnor(const vvm_bitset_t<WIDTH>&l,
{
vvm_bitset_t<WIDTH> result;
for (unsigned idx = 0 ; idx < WIDTH ; idx += 1)
result[idx] = not(l[idx] ^ r[idx]);
result[idx] = v_not(l[idx] ^ r[idx]);
return result;
}
@ -511,7 +511,7 @@ vvm_bitset_t<1> vvm_binop_ne(const vvm_bitset_t<LW>&l,
const vvm_bitset_t<RW>&r)
{
vvm_bitset_t<1> result = vvm_binop_eq(l,r);
result[0] = not(result[0]);
result[0] = v_not(result[0]);
return result;
}
@ -520,7 +520,7 @@ vvm_bitset_t<1> vvm_binop_nee(const vvm_bitset_t<LW>&l,
const vvm_bitset_t<RW>&r)
{
vvm_bitset_t<1> result = vvm_binop_eeq(l,r);
result[0] = not(result[0]);
result[0] = v_not(result[0]);
return result;
}
@ -648,6 +648,9 @@ vvm_bitset_t<W> vvm_ternary(vpip_bit_t c, const vvm_bitset_t<W>&t,
/*
* $Log: vvm_func.h,v $
* Revision 1.20 2000/02/23 04:43:43 steve
* Some compilers do not accept the not symbol.
*
* Revision 1.19 2000/02/23 02:56:56 steve
* Macintosh compilers do not support ident.
*

View File

@ -19,7 +19,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*/
#if !defined(WINNT) && !defined(macintosh)
#ident "$Id: vvm_gates.h,v 1.36 2000/02/23 02:56:57 steve Exp $"
#ident "$Id: vvm_gates.h,v 1.37 2000/02/23 04:43:43 steve Exp $"
#endif
# include "vvm.h"
@ -102,7 +102,7 @@ template <unsigned WIDTH> class vvm_add_sub {
}
void init_Add_Sub(unsigned, vpip_bit_t val)
{ ndir_ = not(val);
{ ndir_ = v_not(val);
}
void start() { compute_(); }
@ -344,7 +344,7 @@ template <unsigned WIDTH> class vvm_compare {
ev->schedule();
}
if (out_le_) {
ev = new vvm_out_event(not(gt_), out_le_);
ev = new vvm_out_event(v_not(gt_), out_le_);
ev->schedule();
}
if (out_gt_) {
@ -352,7 +352,7 @@ template <unsigned WIDTH> class vvm_compare {
ev->schedule();
}
if (out_ge_) {
ev = new vvm_out_event(not(lt_), out_ge_);
ev = new vvm_out_event(v_not(lt_), out_ge_);
ev->schedule();
}
}
@ -724,7 +724,7 @@ template <unsigned long DELAY> class vvm_not : private vvm_1bit_out {
void start() { }
void set_I(unsigned, vpip_bit_t val)
{ output(not(val)); }
{ output(v_not(val)); }
private:
};
@ -963,6 +963,9 @@ template <unsigned WIDTH> class vvm_pevent {
/*
* $Log: vvm_gates.h,v $
* Revision 1.37 2000/02/23 04:43:43 steve
* Some compilers do not accept the not symbol.
*
* Revision 1.36 2000/02/23 02:56:57 steve
* Macintosh compilers do not support ident.
*