[PATCH v1 2/4] GcovData.h: Fix formatting

Ryan Long ryan.long at oarcorp.com
Tue Aug 3 20:30:57 UTC 2021


---
 tester/covoar/GcovData.h | 61 +++++++++++++++++++++++++-----------------------
 1 file changed, 32 insertions(+), 29 deletions(-)

diff --git a/tester/covoar/GcovData.h b/tester/covoar/GcovData.h
index e135ffe..242970f 100644
--- a/tester/covoar/GcovData.h
+++ b/tester/covoar/GcovData.h
@@ -24,17 +24,17 @@ namespace Gcov {
 #define GCNO_VERSION ((uint32_t) 0x34303652 )
 
 /* GCOV tags */
-#define GCOV_TAG_FUNCTION               ((uint32_t)0x01000000)
-#define GCOV_TAG_BLOCKS                 ((uint32_t)0x01410000)
-#define GCOV_TAG_ARCS                   ((uint32_t)0x01430000)
-#define GCOV_TAG_LINES                  ((uint32_t)0x01450000)
-#define GCOV_TAG_COUNTER                ((uint32_t)0x01a10000)
-#define GCOV_TAG_OBJECT_SUMMARY         ((uint32_t)0xa1000000)
-#define GCOV_TAG_PROGRAM_SUMMARY        ((uint32_t)0xa3000000)
+#define GCOV_TAG_FUNCTION        ((uint32_t)0x01000000)
+#define GCOV_TAG_BLOCKS          ((uint32_t)0x01410000)
+#define GCOV_TAG_ARCS            ((uint32_t)0x01430000)
+#define GCOV_TAG_LINES           ((uint32_t)0x01450000)
+#define GCOV_TAG_COUNTER         ((uint32_t)0x01a10000)
+#define GCOV_TAG_OBJECT_SUMMARY  ((uint32_t)0xa1000000)
+#define GCOV_TAG_PROGRAM_SUMMARY ((uint32_t)0xa3000000)
 
 
-typedef std::list<Gcov::GcovFunctionData>              functions_t;
-typedef std::list<Gcov::GcovFunctionData>::iterator    functions_iterator_t;
+typedef std::list<Gcov::GcovFunctionData>           functions_t;
+typedef std::list<Gcov::GcovFunctionData>::iterator functions_iterator_t;
 
 struct gcov_preamble
 {
@@ -96,7 +96,7 @@ class DesiredSymbols;
      *
      *  @return Returns TRUE if the method succeeded and FALSE if it failed.
      */
-    bool writeGcdaFile ();
+    bool writeGcdaFile();
 
     /*!
      *  This method writes all contained information to stdout file
@@ -109,28 +109,28 @@ class DesiredSymbols;
      *  This method runs gcov to generate report. This method should
      *  be used only when gcno and gcda files are already generated.
      */
-    void writeGcovFile( );
+    void writeGcovFile();
 
     /*!
      *  This method calculates values of counters for all functions
      */
-    bool processCounters( void );
+    bool processCounters();
 
   private:
 
-    uint32_t                            numberOfFunctions;
-    gcov_preamble                       gcnoPreamble;
-    std::string                         gcnoFileName;
-    std::string                         gcdaFileName;
-    std::string                         textFileName;
-    std::string                         cFileName;
-    functions_t                         functions;
+    uint32_t      numberOfFunctions;
+    gcov_preamble gcnoPreamble;
+    std::string   gcnoFileName;
+    std::string   gcdaFileName;
+    std::string   textFileName;
+    std::string   cFileName;
+    functions_t   functions;
 
 
     /*!
      *  This method reads a frame from *.gcno file
      *
-     *  @param[in] file points to a file to read
+     *  @param[in] gcovFile points to a file to read
      *
      *  @return true if read was succesfull, false otherwise
      */
@@ -140,9 +140,10 @@ class DesiredSymbols;
      *  This method reads a string from gcov file
      *
      *  @param[in] buffer stores the string
-     *  @param[in] file specifies the name of the file to read
+     *  @param[in] gcovFile specifies the name of the file to read
      *
-     *  @return Returns length of words read (word = 32bit) or -1 if error ocurred
+     *  @return Returns length of words read (word = 32bit) or -1 if error
+     *  ocurred
      */
     int readString( char* buffer, std::ifstream& gcovFile );
 
@@ -150,7 +151,7 @@ class DesiredSymbols;
      *  This method reads a frame header from gcov file
      *
      *  @param[in] header stores the header
-     *  @param[in] file specifies the name of the file to read
+     *  @param[in] gcovFile specifies the name of the file to read
      *
      *  @return Returns length of words read (word = 32bit)
      *  or -1 if error ocurred
@@ -168,9 +169,9 @@ class DesiredSymbols;
      *          or -1 if error ocurred
      */
     int readFilePreamble(
-      gcov_preamble*      preamble,
-      std::ifstream&      gcovFile,
-      const uint32_t      desiredMagic
+      gcov_preamble* preamble,
+      std::ifstream& gcovFile,
+      const uint32_t desiredMagic
     );
 
     /*!
@@ -183,14 +184,16 @@ class DesiredSymbols;
      *  @return Returns true if operation was succesfull
      */
     bool readFunctionFrame(
-      gcov_frame_header   header,
-      std::ifstream&      gcovFile,
-      GcovFunctionData*   function
+      gcov_frame_header header,
+      std::ifstream&    gcovFile,
+      GcovFunctionData* function
     );
 
     /*!
      *  This method prints info about previously read *.gcno file
      *  to a specified report file
+     *
+     *  @param[in] textFile specifies output file
      */
     void printGcnoFileInfo( std::ofstream& textFile );
 
-- 
1.8.3.1



More information about the devel mailing list