File tree Expand file tree Collapse file tree 3 files changed +13
-9
lines changed Expand file tree Collapse file tree 3 files changed +13
-9
lines changed Original file line number Diff line number Diff line change @@ -35,9 +35,13 @@ target_link_libraries(c++spec INTERFACE
35
35
)
36
36
37
37
FILE (GLOB_RECURSE c++spec_headers ${CMAKE_CURRENT_LIST_DIR} /include/*.hpp )
38
- target_precompile_headers (c++spec INTERFACE
39
- ${c++spec_headers}
40
- )
38
+
39
+ option (CPPSPEC_PRECOMPILE_HEADERS "Precompile the C++Spec headers" )
40
+ if (CPPSPEC_PRECOMPILE_HEADERS )
41
+ target_precompile_headers (c++spec INTERFACE
42
+ ${c++spec_headers}
43
+ )
44
+ endif ()
41
45
42
46
# HELPERS
43
47
@@ -79,7 +83,7 @@ if(CPPSPEC_BUILD_EXAMPLES)
79
83
add_subdirectory (examples )
80
84
endif (CPPSPEC_BUILD_EXAMPLES )
81
85
82
- ##### Documentation generation #######
86
+ # #### Documentation generation #######
83
87
if (CPPSPEC_BUILD_DOCS )
84
88
find_package (Doxygen
85
89
OPTIONAL_COMPONENTS dot mscgen dia
Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ struct RuntimeOpts {
26
26
std::shared_ptr<Formatters::BaseFormatter> formatter = nullptr ;
27
27
};
28
28
29
- inline Runner parse (int argc, char ** argv) {
29
+ inline Runner parse (int argc, char ** const argv) {
30
30
argparse::ArgumentParser program{file_name (argv[0 ])};
31
31
32
32
program.add_argument (" -f" , " --format" )
@@ -64,4 +64,4 @@ inline Runner parse(int argc, char** argv) {
64
64
65
65
return Runner{opts.formatter };
66
66
}
67
- } // namespace CppSpec
67
+ } // namespace CppSpec
Original file line number Diff line number Diff line change 37
37
#define before_each self.before_each
38
38
#define after_all self.after_all
39
39
#define after_each self.after_each
40
- #define let (name, body ) auto (name) = self.let(body);
40
+ #define let (name, body ) auto (name) = self.let(body);
41
41
42
42
#define CPPSPEC_MAIN (spec ) \
43
- int main (int argc, char **argv) { \
43
+ int main (int argc, char **const argv) { \
44
44
return CppSpec::parse (argc, argv).add_spec (spec).exec () ? EXIT_SUCCESS \
45
45
: EXIT_FAILURE; \
46
46
}
47
47
48
48
#define CPPSPEC_SPEC (spec_name ) \
49
- int spec_name_spec (int argc, char **argv) { \
49
+ int spec_name_spec (int argc, char **const argv) { \
50
50
return CppSpec::parse (argc, argv).add_spec (spec_name).exec () \
51
51
? EXIT_SUCCESS \
52
52
: EXIT_FAILURE; \
You can’t perform that action at this time.
0 commit comments