review fixes

This commit is contained in:
Alexander Kuzmenkov 2020-04-02 13:02:51 +03:00
parent ed5c6bff5e
commit 338c18ae3b

View File

@ -200,14 +200,10 @@ static String getUniqueName(ActionsVisitor::Data & data, const String & prefix)
auto & block = data.getSampleBlock();
auto result = prefix;
if (block.has(result))
while (block.has(result))
{
do
{
result = prefix + "_" + toString(data.next_unique_suffix);
++data.next_unique_suffix;
}
while (block.has(result));
result = prefix + "_" + toString(data.next_unique_suffix);
++data.next_unique_suffix;
}
return result;