mirror of https://github.com/YosysHQ/yosys.git
hashlib: only include in one place
This commit is contained in:
parent
c26f625b27
commit
e626fafa5e
|
@ -34,6 +34,8 @@ namespace hashlib {
|
|||
* Hashlib doesn't know how to hash silly Yosys-specific types.
|
||||
* Hashlib doesn't depend on Yosys and can be used standalone.
|
||||
* Please don't use hashlib standalone for new projects.
|
||||
* Never directly include kernel/hashlib.h in Yosys code.
|
||||
* Instead include kernel/yosys_common.h
|
||||
*
|
||||
* The hash_ops type is now always left to its default value, derived
|
||||
* from templated functions through SFINAE. Providing custom ops is
|
||||
|
|
|
@ -157,8 +157,7 @@ YOSYS_NAMESPACE_BEGIN
|
|||
// Note: All headers included in hashlib.h must be included
|
||||
// outside of YOSYS_NAMESPACE before this or bad things will happen.
|
||||
#ifdef HASHLIB_H
|
||||
# undef HASHLIB_H
|
||||
# include "kernel/hashlib.h"
|
||||
# error You've probably included hashlib.h under two namespace paths. Bad idea.
|
||||
#else
|
||||
# include "kernel/hashlib.h"
|
||||
# undef HASHLIB_H
|
||||
|
|
|
@ -20,7 +20,6 @@
|
|||
#include "kernel/register.h"
|
||||
#include "kernel/rtlil.h"
|
||||
#include "kernel/log.h"
|
||||
#include "kernel/hashlib.h"
|
||||
|
||||
USING_YOSYS_NAMESPACE
|
||||
PRIVATE_NAMESPACE_BEGIN
|
||||
|
|
Loading…
Reference in New Issue