From 8e3ca71bdacf0104c842c23b7e4e195e6b19cef9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20M=C3=BCller?= Date: Tue, 17 Jun 2025 18:03:42 +0200 Subject: [PATCH] Update type definitions to "using" instead of "typedef" --- include/aoc/DiskFragmenter.hpp | 4 ++-- include/aoc/GuardGallivant.hpp | 4 ++-- include/aoc/ReindeerMaze.hpp | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/include/aoc/DiskFragmenter.hpp b/include/aoc/DiskFragmenter.hpp index 7a16338..4413138 100644 --- a/include/aoc/DiskFragmenter.hpp +++ b/include/aoc/DiskFragmenter.hpp @@ -30,8 +30,8 @@ class DiskFragmenter virtual void processDataLine(const std::string& line) override; virtual void finish() override; private: - typedef std::vector Intervals; - typedef std::array DigitIndexArray; + using Intervals = std::vector; + using DigitIndexArray = std::array; void moveFileBlocks(const std::string& line); void moveWholeFiles(const std::string& line); void AddNewEmptySpaces(Intervals& emptySpaces, const std::string& line, size_t& front, const size_t back, diff --git a/include/aoc/GuardGallivant.hpp b/include/aoc/GuardGallivant.hpp index 1ad59ef..414254f 100644 --- a/include/aoc/GuardGallivant.hpp +++ b/include/aoc/GuardGallivant.hpp @@ -30,8 +30,8 @@ class GuardGallivant virtual const int getPuzzleDay() const override; virtual void finish() override; private: - typedef Grid VisitGrid; - typedef Grid> PathGrid; + using VisitGrid = Grid; + using PathGrid = Grid>; static constexpr size_t getStartDirectionIndex(); static constexpr char getStartChar(); static constexpr char getObstructionChar(); diff --git a/include/aoc/ReindeerMaze.hpp b/include/aoc/ReindeerMaze.hpp index 3d0d648..69d0e60 100644 --- a/include/aoc/ReindeerMaze.hpp +++ b/include/aoc/ReindeerMaze.hpp @@ -34,7 +34,7 @@ class ReindeerMaze virtual const int getPuzzleDay() const override; virtual void finish() override; private: - typedef std::map> VertexAttachedPositions; + using VertexAttachedPositions = std::map>; static constexpr char getStartChar(); static constexpr char getEndChar(); static constexpr char getWallChar();