Make duplicated function name checker working (#705)
This commit is contained in:
Родитель
770b904b37
Коммит
51223c38bf
|
@ -36,3 +36,4 @@ List of Contributors
|
||||||
- [Jian Weng](https://github.com/were)
|
- [Jian Weng](https://github.com/were)
|
||||||
- [Masahiro Masuda](https://github.com/masahi)
|
- [Masahiro Masuda](https://github.com/masahi)
|
||||||
- [Haolong Zhang](https://github.com/haolongzhangm)
|
- [Haolong Zhang](https://github.com/haolongzhangm)
|
||||||
|
- [Cody Hao Yu](https://github.com/comaniac)
|
||||||
|
|
|
@ -310,6 +310,7 @@ def build(sch,
|
||||||
raise ValueError("sch have to be Schedule, LoweredFunc or list of LoweredFunc")
|
raise ValueError("sch have to be Schedule, LoweredFunc or list of LoweredFunc")
|
||||||
if x.name in fname_set:
|
if x.name in fname_set:
|
||||||
raise ValueError("Duplicate function name %s" % x.name)
|
raise ValueError("Duplicate function name %s" % x.name)
|
||||||
|
fname_set.add(x.name)
|
||||||
|
|
||||||
target = _target.current_target() if target is None else target
|
target = _target.current_target() if target is None else target
|
||||||
target = _target.create(target) if target else _target.create("llvm")
|
target = _target.create(target) if target else _target.create("llvm")
|
||||||
|
|
Загрузка…
Ссылка в новой задаче