mirror of
https://github.com/YosysHQ/yosys
synced 2025-08-01 17:03:19 +00:00
Progress in memory_bram
This commit is contained in:
parent
94e6b70736
commit
327a5d42b6
4 changed files with 127 additions and 15 deletions
|
@ -250,14 +250,14 @@ namespace RTLIL
|
|||
// of cell types). the following functions helps with that.
|
||||
|
||||
template<typename T, typename... Args>
|
||||
bool in(T first, Args... rest) {
|
||||
bool in(T first, Args... rest) const {
|
||||
return in(first) || in(rest...);
|
||||
}
|
||||
|
||||
bool in(IdString rhs) { return *this == rhs; }
|
||||
bool in(const char *rhs) { return *this == rhs; }
|
||||
bool in(const std::string &rhs) { return *this == rhs; }
|
||||
bool in(const pool<IdString> &rhs) { return rhs.count(*this) != 0; }
|
||||
bool in(IdString rhs) const { return *this == rhs; }
|
||||
bool in(const char *rhs) const { return *this == rhs; }
|
||||
bool in(const std::string &rhs) const { return *this == rhs; }
|
||||
bool in(const pool<IdString> &rhs) const { return rhs.count(*this) != 0; }
|
||||
};
|
||||
|
||||
static inline std::string escape_id(std::string str) {
|
||||
|
|
|
@ -137,6 +137,8 @@ YOSYS_NAMESPACE_BEGIN
|
|||
|
||||
using std::vector;
|
||||
using std::string;
|
||||
using std::pair;
|
||||
|
||||
using hashlib::mkhash;
|
||||
using hashlib::mkhash_init;
|
||||
using hashlib::mkhash_add;
|
||||
|
@ -221,6 +223,8 @@ YOSYS_NAMESPACE_END
|
|||
|
||||
YOSYS_NAMESPACE_BEGIN
|
||||
|
||||
using RTLIL::State;
|
||||
|
||||
namespace hashlib {
|
||||
template<> struct hash_ops<RTLIL::State> : hash_ops<int> {};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue