amaranth/amaranth
Charlotte 4ec9cbbffe sim._pyrtl: py3.12+: convert to int before bitwise negating.
Amaranth bitwise negation `~` compiles to Python bitwise negation `~` in
simulation; the same holds for comparison operators such as `==`. Thus
an expression such as `~(a == b)` in simulation will compile to Python
that takes the bitwise negation of the comparison result, which will be
an actual bool.

On 3.12, the result is a `DeprecationWarning` emitted only at simulation
run-time.

When negating in simulation, coerce the value to an int. `mask` is
sufficient as we do no further arithmetic here.
2023-06-22 17:37:30 +00:00
..
_toolchain _toolchain.cxx: remove. 2023-06-02 13:45:15 +01:00
back hdl.ast: deprecate Repl and remove from AST; add Value.replicate. 2023-06-22 03:52:55 +00:00
build build.plat: replace -+ characters in _all_toolchain_env_vars. 2023-05-15 18:25:49 +01:00
compat hdl.ast: deprecate Repl and remove from AST; add Value.replicate. 2023-06-22 03:52:55 +00:00
hdl hdl.ast: deprecate Repl and remove from AST; add Value.replicate. 2023-06-22 03:52:55 +00:00
lib lib.data: warn if a field is shadowed by an attribute of the view. 2023-05-31 13:27:20 +01:00
sim sim._pyrtl: py3.12+: convert to int before bitwise negating. 2023-06-22 17:37:30 +00:00
vendor hdl.ast: deprecate Repl and remove from AST; add Value.replicate. 2023-06-22 03:52:55 +00:00
__init__.py Rename nMigen to Amaranth HDL. 2021-12-10 10:34:13 +00:00
_unused.py Rename nMigen to Amaranth HDL. 2021-12-10 10:34:13 +00:00
_utils.py hdl.ast: deprecate Sample, Past, Rose, Fell, Stable. 2023-02-28 14:30:04 +00:00
asserts.py Rename nMigen to Amaranth HDL. 2021-12-10 10:34:13 +00:00
cli.py back.rtlil,cli: allow suppressing generation of src attributes. 2021-12-11 11:38:40 +00:00
rpc.py Rename nMigen to Amaranth HDL. 2021-12-10 10:34:13 +00:00
tracer.py tracer: fix STORE_DEREF handling, add EXTENDED_ARG support. 2023-06-01 19:18:43 +01:00
utils.py Rename nMigen to Amaranth HDL. 2021-12-10 10:34:13 +00:00