Re: [PATCH 1/1] rust: macros: fix redefine const_name in `vtable`

From: Martin Rodriguez Reboredo
Date: Mon Jun 26 2023 - 12:49:46 EST


On 6/26/23 04:42, Qingsong Chen wrote:
If the trait has same function name, the `vtable` macro
will redefine its `gen_const_name`, e.g.:
```rust
#[vtable]
pub trait Foo {
#[cfg(CONFIG_X)]
fn bar();

#[cfg(not(CONFIG_X))]
fn bar(x: usize);
}
```
Use `HashSet` to avoid this.

Signed-off-by: Qingsong Chen <changxian.cqs@xxxxxxxxxxxx>
---
[...]
Reviewed-by: Martin Rodriguez Reboredo <yakoyoku@xxxxxxxxx>