Alex Lorenz | e82d89c | 2014-08-22 22:56:03 +0000 | [diff] [blame] | 1 | //===- CoverageViewOptions.h - Code coverage display options -------------===// |
| 2 | // |
| 3 | // The LLVM Compiler Infrastructure |
| 4 | // |
| 5 | // This file is distributed under the University of Illinois Open Source |
| 6 | // License. See LICENSE.TXT for details. |
| 7 | // |
| 8 | //===----------------------------------------------------------------------===// |
| 9 | |
| 10 | #ifndef LLVM_COV_COVERAGEVIEWOPTIONS_H |
| 11 | #define LLVM_COV_COVERAGEVIEWOPTIONS_H |
| 12 | |
| 13 | #include "RenderingSupport.h" |
| 14 | |
| 15 | namespace llvm { |
| 16 | |
| 17 | /// \brief The options for displaying the code coverage information. |
| 18 | struct CoverageViewOptions { |
Vedant Kumar | 635c83c | 2016-06-28 00:15:54 +0000 | [diff] [blame^] | 19 | enum class OutputFormat { |
| 20 | Text |
| 21 | }; |
| 22 | |
Alex Lorenz | e82d89c | 2014-08-22 22:56:03 +0000 | [diff] [blame] | 23 | bool Debug; |
| 24 | bool Colors; |
| 25 | bool ShowLineNumbers; |
| 26 | bool ShowLineStats; |
| 27 | bool ShowRegionMarkers; |
| 28 | bool ShowLineStatsOrRegionMarkers; |
| 29 | bool ShowExpandedRegions; |
| 30 | bool ShowFunctionInstantiations; |
Vedant Kumar | c3c39e7 | 2015-09-14 23:26:36 +0000 | [diff] [blame] | 31 | bool ShowFullFilenames; |
Vedant Kumar | 635c83c | 2016-06-28 00:15:54 +0000 | [diff] [blame^] | 32 | OutputFormat ShowFormat; |
Alex Lorenz | e82d89c | 2014-08-22 22:56:03 +0000 | [diff] [blame] | 33 | |
| 34 | /// \brief Change the output's stream color if the colors are enabled. |
| 35 | ColoredRawOstream colored_ostream(raw_ostream &OS, |
| 36 | raw_ostream::Colors Color) const { |
| 37 | return llvm::colored_ostream(OS, Color, Colors); |
| 38 | } |
| 39 | }; |
| 40 | } |
| 41 | |
| 42 | #endif // LLVM_COV_COVERAGEVIEWOPTIONS_H |