Skip to content

Commit e24fe3c

Browse files
committed
Trim whitespace
1 parent e55d3c9 commit e24fe3c

17 files changed

+63
-71
lines changed

Bloaty.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ endmacro()
122122

123123
function(swift_add_bloaty target)
124124
eval_bloaty_target(${target})
125-
125+
126126
set(argOption SEGMENTS SECTIONS SYMBOLS COMPILEUNITS LOG_TOTAL_MEMORY)
127127
set(argSingle NUM SORT WORKING_DIRECTORY REPORT_DIRECTORY)
128128
set(argMulti LOG_TOTAL_MEMORY_OPTIONS)

ClangFormat.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@
8080
#
8181
# The default value is ON for top level projects, and OFF for any others.
8282
#
83-
# Running
83+
# Running
8484
#
8585
# cmake -D<project>_ENABLE_CLANG_FORMAT=OFF ..
8686
#
@@ -211,7 +211,7 @@ function(swift_setup_clang_format)
211211

212212
# First try to find clang-format
213213
if(NOT x_CLANG_FORMAT_NAMES)
214-
set(x_CLANG_FORMAT_NAMES
214+
set(x_CLANG_FORMAT_NAMES
215215
clang-format60 clang-format-6.0
216216
clang-format40 clang-format-4.0
217217
clang-format39 clang-format-3.9

CompileOptions.cmake

Lines changed: 16 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -21,41 +21,41 @@
2121
# - Warnings as errors (-Werror)
2222
# - Extensive set of enabled warnings
2323
#
24-
# Exceptions and/or RTTI can be selectively enabled for a
25-
# target be passing EXCEPTIONS and/or RTTI as a parameter, eg
24+
# Exceptions and/or RTTI can be selectively enabled for a
25+
# target be passing EXCEPTIONS and/or RTTI as a parameter, eg
2626
#
2727
# swift_set_compile_options(sample-target EXCEPTIONS RTTI)
2828
#
2929
# will enable exceptions and rtti for sample-target only
3030
#
3131
# Warning flags can be removed from the default set by passing
32-
# REMOVE followed by a list of warning flags, eg
32+
# REMOVE followed by a list of warning flags, eg
3333
#
3434
# swift_set_compile_options(sample-target REMOVE -Wconversion)
3535
#
36-
# will prevent -Wconversion from being passed to the compiler
37-
# for sample-target only
36+
# will prevent -Wconversion from being passed to the compiler
37+
# for sample-target only
3838
#
39-
# Similarly extra options can be given by passing ADD followed
40-
# by a list of warning flags (or other compiler options), eg
39+
# Similarly extra options can be given by passing ADD followed
40+
# by a list of warning flags (or other compiler options), eg
4141
#
4242
# swift_set_compile_options(sample-target ADD -Wformat=2)
4343
#
44-
# will pass -Wformat=2 to the compiler for sample-target only
44+
# will pass -Wformat=2 to the compiler for sample-target only
4545
#
46-
# By default -Werror is set, but this can be prevented by passing
47-
# WARNING as a parameter, eg
46+
# By default -Werror is set, but this can be prevented by passing
47+
# WARNING as a parameter, eg
4848
#
4949
# swift_set_compile_options(sample-target WARNING)
5050
#
51-
# will disable warnings-as-errors for sample-target only
51+
# will disable warnings-as-errors for sample-target only
5252
#
5353
# All flags will be checked for suitability with the in-use
54-
# compilers before being selected. This is important since
55-
# Swift code tends to be compiled with a wide variety of
56-
# compilers which may not support the same set of flags and
57-
# options. Therefore, it should be preferred to use this
58-
# function to set compiler flags and options rather than
54+
# compilers before being selected. This is important since
55+
# Swift code tends to be compiled with a wide variety of
56+
# compilers which may not support the same set of flags and
57+
# options. Therefore, it should be preferred to use this
58+
# function to set compiler flags and options rather than
5959
# target_compile_options()
6060
#
6161

@@ -230,4 +230,3 @@ function(swift_set_compile_options)
230230
endforeach()
231231

232232
endfunction()
233-

FindEigen.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,3 @@ else()
2323
target_include_directories(eigen SYSTEM INTERFACE
2424
${PROJECT_SOURCE_DIR}/third_party/eigen/)
2525
endif()
26-

FindGProf.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,4 +20,4 @@ if (NOT GProf_FOUND)
2020
set(GProf_FOUND ${GProf_FOUND} CACHE BOOL "Flag whether GProf package was found")
2121
mark_as_advanced(GProf_FOUND GProf_EXECUTABLE)
2222

23-
endif ()
23+
endif()

FindJson.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,3 @@ GenericFindDependency(
1717
SOURCE_DIR "json"
1818
SYSTEM_INCLUDES
1919
)
20-

FindNanopb.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,3 @@ GenericFindDependency(
1717
SOURCE_DIR "nanopb"
1818
SYSTEM_INCLUDES
1919
)
20-

FindRapidCheck.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,3 @@ GenericFindDependency(
2121
rapidcheck_gtest
2222
SYSTEM_INCLUDES
2323
)
24-

FindValgrind.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,4 +20,4 @@ if (NOT Valgrind_FOUND)
2020
set(Valgrind_FOUND ${Valgrind_FOUND} CACHE BOOL "Flag whether Valgrind package was found")
2121
mark_as_advanced(Valgrind_FOUND Valgrind_EXECUTABLE)
2222

23-
endif ()
23+
endif()

GenericFindDependency.cmake

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
# in the host system or cross compiling sysroot.
2020
#
2121
# By default dependencies are first sought in bundled source code, and if not
22-
# found from the system libraries. This default behaviour can be controlled by
22+
# found from the system libraries. This default behaviour can be controlled by
2323
# several options
2424
#
2525
# EXCLUDE - can be used to disable searching in a particular location. Valid
@@ -40,14 +40,14 @@
4040
# create an interface target which can be used to link in to any other target.
4141
#
4242
# The options "SYSTEM_HEADER_FILE" and "SYSTEM_LIB_NAMES" will be passed verbatim
43-
# to the cmake functions find_header() and find_library() to search all the
43+
# to the cmake functions find_header() and find_library() to search all the
4444
# correct system locations.
4545
#
4646
# When using bundled source code the function will search several default locations
4747
# under '${CMAKE_CURRENT_SOURCE_DIR}/third_party' based on the package and target
4848
# names. The search location can be controlled by the "SOURCE_DIR" parameter
4949
#
50-
# The target name can be controlled by the option "TARGET". When using
50+
# The target name can be controlled by the option "TARGET". When using
5151
# bundled source code this is used to verify the target was created properly
5252
# after calling add_subdirectory. If the add_subdirectory exposes a number of
5353
# other targets, you can use the "ADDITIONAL_TARGETS" option to list them, this
@@ -86,7 +86,7 @@ function(search_dependency_source)
8686
message(STATUS "Found ${x_TARGET} source code in ${P}")
8787
# Function arguments are automatically parsed out in to numbered variables
8888
# ARG#, and a complete argument list is stored in ARGN. Variables are passed
89-
# down the function call stack until they are overwritten. This allows a
89+
# down the function call stack until they are overwritten. This allows a
9090
# badly written function to test for the existance of an optional variable
9191
# in it's own argument list but actually pick up a variable for a function
9292
# much higher up the call stack.
@@ -100,12 +100,12 @@ function(search_dependency_source)
100100
# here.
101101
#
102102
# This is a very ugly way of mitigating the error. We manually unset all
103-
# the cmake variable related to function arguments immediately before
103+
# the cmake variable related to function arguments immediately before
104104
# including the dependency project. This will make it APPEAR as though
105105
# add_subdirectory was called from outside a function or macro.
106106
#
107107
# Note the limitation, argument lists are apparently unlimited, we are only
108-
# unsetting the first 100 argument variables. This will probably be enough
108+
# unsetting the first 100 argument variables. This will probably be enough
109109
# as I haven't seen functions taking that many arguments, but it certainly
110110
# isn't bulletproof. Cmake doesn't appear to have any functionality which
111111
# could be used to achieve this so we are left with few, if any, other options.
@@ -119,7 +119,7 @@ function(search_dependency_source)
119119
#
120120
# Additionally, cmake variable are only propogated down the stack, not up
121121
# (unless PARENT_SCOPE is used in set()) so by unsetting variables here we
122-
# won't affect whatever function called us, or anything even higher up
122+
# won't affect whatever function called us, or anything even higher up
123123
# the call stack.
124124
foreach(i RANGE 0 100)
125125
unset(ARGV${i})
@@ -134,11 +134,11 @@ function(search_dependency_source)
134134
OUTPUT_STRIP_TRAILING_WHITESPACE
135135
)
136136
file(WRITE ${CMAKE_BINARY_DIR}/submodule-checks/${x_TARGET}.used "${GIT_COMMIT} ${P}\n")
137-
137+
138138
if(NOT TARGET ${x_TARGET})
139139
message(WARNING "Source code in ${P} did not declare target ${x_TARGET} as was expected")
140140
endif()
141-
141+
142142
# This is very ugly, but required for some python modules, it will not last beyond this temporary solution
143143
if(EXISTS "${P}/include")
144144
set(x_${x_TARGET}_IncludeDir "${P}/include" CACHE PATH "Path to ${x_TARGET} bundled source code header files")
@@ -188,7 +188,7 @@ endfunction()
188188
# This macro will return(), ie cause the caller to return, if there are no available locations.
189189
# It will raise a fatal error if unknown values are specified for any of the input parameters.
190190
#
191-
# Inputs:
191+
# Inputs:
192192
# - x_PREFER - Parameter to GenericFindDependency, preferred location as defined by the project
193193
# - SWIFT_PREFERRED_DEPENDENCY_SOURCE - Global user preference, defined on the command line
194194
# - x_EXCLUDE - List of sources to exclude from consideration
@@ -355,7 +355,7 @@ function(GenericFindDependency)
355355
TARGET "${x_TARGET}"
356356
SOURCE_SEARCH_PATHS "${x_SOURCE_SEARCH_PATHS}"
357357
)
358-
358+
359359
# If the expected target was created we have succeeded
360360
if(TARGET ${x_TARGET})
361361
message(STATUS "Using dependency ${x_TARGET} from bundled source code")
@@ -407,4 +407,3 @@ function(GenericFindDependency)
407407
endif()
408408
endforeach()
409409
endfunction()
410-

0 commit comments

Comments
 (0)