Added ID() macro for static IdStrings

This commit is contained in:
Clifford Wolf 2014-08-03 14:59:13 +02:00
parent 014a41fcf3
commit 75423169c5
1 changed files with 3 additions and 0 deletions

View File

@ -103,6 +103,9 @@ RTLIL::IdString new_id(std::string file, int line, std::string func);
#define NEW_ID \
YOSYS_NAMESPACE_PREFIX new_id(__FILE__, __LINE__, __FUNCTION__)
#define ID(_str) \
([]() { static YOSYS_NAMESPACE_PREFIX RTLIL::IdString _id(_str); return _id; })()
RTLIL::Design *yosys_get_design();
std::string proc_self_dirname();
std::string proc_share_dirname();