We have some protocols that do the following:
#[idle]
prot idle<DUT: ReadSubordinate>() {
// ....
}
#[idle]
prot idle<DUT: WriteSubordinate>() {
// ...
}
This seems like a totally legitimate thing to do. However, it kind of violates some rules around duplicate names that one would expect from a programming language. Namely that you cannot have two functions in the same scope that are both named idle.
Maybe it is time to switch to more of a impl style protocol definition. Like:
impl ReadSubordinate {
#[idle]
prot idle(DUT: Self) {
// ....
}
}
impl WriteSubordinate{
#[idle]
prot idle(DUT: Self) {
// ....
}
}
I don't necessarily like the DUT: Self. Another option would be a magic self or even a magic dut.
We have some protocols that do the following:
This seems like a totally legitimate thing to do. However, it kind of violates some rules around duplicate names that one would expect from a programming language. Namely that you cannot have two functions in the same scope that are both named
idle.Maybe it is time to switch to more of a
implstyle protocol definition. Like:I don't necessarily like the
DUT: Self. Another option would be a magicselfor even a magicdut.