Permalink
Browse files

Remove old warnOnNewTag function

  • Loading branch information...
lauft committed Jul 31, 2018
1 parent 6888533 commit a02b98fd4f5e5d33828e7fc702c1b7c124b56ae8
Showing with 0 additions and 35 deletions.
  1. +0 −35 src/validate.cpp
@@ -161,39 +161,6 @@ static void autoAdjust (
}
}

////////////////////////////////////////////////////////////////////////////////
// Warn on new tag.
static void warnOnNewTag (
const Rules&,
Database&,
const Interval&)
{
// TODO This warning is not working properly, because when an interval is
// modified, it is first deleted, then added. This causes this code to
// determine that it is always a new tag.
/*
if (rules.getBoolean ("verbose"))
{
std::set <std::string> tags;
for (auto& line : database.allLines ())
{
if (line[0] == 'i')
{
Interval interval;
interval.initialize (line);
for (auto& tag : interval.tags ())
tags.insert (tag);
}
}
for (auto& tag : interval.tags ())
if (tags.find (tag) == tags.end ())
std::cout << "Note: '" << tag << "' is a new tag.\n";
}
*/
}

////////////////////////////////////////////////////////////////////////////////
void validate (
const CLI& cli,
@@ -211,8 +178,6 @@ void validate (
autoFill (rules, database, interval);

autoAdjust (findHint (cli, ":adjust"), rules, database, interval);

warnOnNewTag (rules, database, interval);
}

////////////////////////////////////////////////////////////////////////////////

0 comments on commit a02b98f

Please sign in to comment.