From 3ef6759aa81b279085a7bdd51cac94f1ba721915 Mon Sep 17 00:00:00 2001 From: Romain Brenguier Date: Fri, 9 Feb 2018 13:02:26 +0000 Subject: [PATCH] Rearrange cover_basic_blocks header Put type definition at the beggining. Remove typedef that are used only once (they hide what the type actually is). Use private membres instead of protected. --- src/goto-instrument/cover_basic_blocks.h | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/src/goto-instrument/cover_basic_blocks.h b/src/goto-instrument/cover_basic_blocks.h index 8a50476f606..674dbfd07c5 100644 --- a/src/goto-instrument/cover_basic_blocks.h +++ b/src/goto-instrument/cover_basic_blocks.h @@ -23,7 +23,7 @@ class cover_basic_blockst public: struct block_infot { - /// the program location to instrument for this block + /// the program instruction representative for this block optionalt representative_inst; /// the source location representative for this block @@ -31,7 +31,6 @@ class cover_basic_blockst // the line number ranges to them) source_locationt source_location; - // map block numbers to source code locations /// the set of lines belonging to this block std::unordered_set lines; }; @@ -72,14 +71,10 @@ class cover_basic_blockst /// Outputs the list of blocks void output(std::ostream &out) const; -protected: +private: // map program locations to block numbers - typedef std::map block_mapt; - block_mapt block_map; - - typedef std::vector block_infost; - block_infost block_infos; - + std::map block_map; + std::vector block_infos; }; #endif // CPROVER_GOTO_INSTRUMENT_COVER_BASIC_BLOCKS_H