Don't try to find duplicate references, this is stupid
Signed-off-by: Username404-59 <w.iron.zombie@gmail.com>
This commit is contained in:
parent
888c75a31e
commit
fa874ef0d2
|
@ -24,18 +24,18 @@ private:
|
|||
unordered_task_map getTaskMapInstance() final { // TODO Include line in error messages
|
||||
using namespace StandardComponents;
|
||||
return {
|
||||
make_nonlocal_task(Reference,
|
||||
make_nonlocal_task(Function,
|
||||
if (index > 0 and any_of(parsedTree.cbegin(), parsedTree.cbegin() + index + 1, [&parseComponent](const component_ptr& pointer){
|
||||
if (pointer->getId() != typeid(Reference)) {
|
||||
try {
|
||||
return dynamic_cast<NamedIdentifier<true>&>(*pointer).name == parseComponent.name;
|
||||
} catch (const bad_cast&) {
|
||||
return false;
|
||||
} catch (const bad_cast&) {};
|
||||
}
|
||||
return false;
|
||||
})) { error(parseComponent.name + " has already been defined previously"); }
|
||||
),
|
||||
share_task(Reference, Function),
|
||||
share_task(Reference, Class),
|
||||
share_task(Reference, Define<true>),
|
||||
share_task(Function, Class),
|
||||
share_task(Function, Define<true>),
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue