clang-tidy: use auto

Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
Rosen Penev
2022-03-04 00:43:44 -08:00
parent 962e3b7369
commit 04bacdedd6
29 changed files with 62 additions and 62 deletions
+3 -3
View File
@@ -672,14 +672,14 @@ namespace Exiv2::Internal {
std::ostream& PanasonicMakerNote::printAccelerometer(std::ostream& os, const Value& value, const ExifData*)
{
// value is stored as unsigned int, but should be read as int16_t.
const int16_t i = static_cast<int16_t>(value.toInt64());
const auto i = static_cast<int16_t>(value.toInt64());
return os << i;
} // PanasonicMakerNote::printAccelerometer
std::ostream& PanasonicMakerNote::printRollAngle(std::ostream& os, const Value& value, const ExifData*)
{
// value is stored as unsigned int, but should be read as int16_t.
const int16_t i = static_cast<int16_t>(value.toInt64());
const auto i = static_cast<int16_t>(value.toInt64());
std::ostringstream oss;
oss.copyfmt(os);
os << std::fixed << std::setprecision(1) << i / 10.0;
@@ -691,7 +691,7 @@ namespace Exiv2::Internal {
std::ostream& PanasonicMakerNote::printPitchAngle(std::ostream& os, const Value& value, const ExifData*)
{
// value is stored as unsigned int, but should be read as int16_t.
const int16_t i = static_cast<int16_t>(value.toInt64());
const auto i = static_cast<int16_t>(value.toInt64());
std::ostringstream oss;
oss.copyfmt(os);
os << std::fixed << std::setprecision(1) << -i / 10.0;