| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|\
| |
| |
| |
| |
| |
| | |
935fbe0b04 cmStringAlgorithms: Add cmStrToLong and cmStrToULong
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !3681
|
| |
| |
| |
| |
| |
| |
| |
| | |
This adds the following functions to cmStringAlgorithms:
- `cmStrToLong`: moved from `cmSystemTools::StringToLong`
- `cmStrToULong`: moved from `cmSystemTools::StringToULong`
Overloads of the given functions for `std::string` are added as well.
|
|/
|
|
|
| |
- Add `cmRemoveQuotes` function to cmStringAlgorithms
- Remove unused removeQuotes inline functions
|
|
|
|
|
| |
Extend the testStringAlgorithms test with tests for `cmTrimWhitespace`,
`cmEscapeQuotes` and `cmTokenize`.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
An old workaround for `std::allocator_traits<>::value_type` lints from
IWYU on `std::vector<>` usage breaks IWYU's handling of `<memory>`.
Convert the workaround to use the same approach we already use for a
workaround of `std::__decay_and_strip<>::::__type` lints. Then update
the `<memory>` inclusions to follow the now-correct IWYU lints.
|
|
|
|
|
|
|
|
|
| |
This class is ultimately intended as a replacement for cmsys::Process.
It spawns a series of processes using libuv, piping the output of each
command into the next.
Note: input support has not yet been implemented because write
support has not yet been implemented on cmUVStreambuf.
|
|
|
|
|
| |
This will allow std::istream/std::ostream-based interaction with
processes spawned by libuv.
|
| |
|
|
|
|
| |
Fixes: #19161
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
b783e62533 cmExecuteProcessCommand: Port to cmArgumentParser
9bddb03f31 cmParseArgumentsCommand: Port to cmArgumentParser
45edf1ad66 Retire cmCommandArgumentsHelper
f5acecaa6f cmExportCommand: Port to cmArgumentParser
e6b6bb0618 cmInstallCommand: Port to cmArgumentParser
4336a29edd cmFileCommand: Port to cmArgumentParser
4359fe133b Introduce cmArgumentParser
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Leonid Pospelov <pospelovlm@yandex.ru>
Merge-request: !3137
|
| | |
|
|/ |
|
| |
|
| |
|
|
|
|
|
| |
These are invalid because the Unicode standard says so (because UTF-16
as specified today cannot encode them).
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Suppress one in code generated by flex.
|
|
|
|
|
| |
IWYU now correctly requires `<utility>` for `std::move`. It also
requires a container header when used via a range-based for loop.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The `str()` method must be non-const because it may need to internally
mutate the representation of the string in order to have an owned
`std::string` instance holding the exact string (not a superstring).
This is inconvenient in contexts where we can ensure that no mutation
is needed to get a `std::string const&`.
Add a `str_if_stable() const` method that returns `std::string const*`
so we can return `nullptr` if if mutation would be necessary to get a
`std::string const&`. Add supporting `is_stable() const` and
`stabilize()` methods to check and enforce stable availability of
`std::string const&`. These can be used to create `String const`
instances from which we can still get a `std::string const&` via
`*str_if_stable()` by maintaining the stability invariant at runtime.
|
|
|
|
|
| |
Create a `static_string_view` type that binds only to the static storage
of string literals. Teach `cm::String` to borrow from these implicitly.
|
|
|
|
|
|
| |
This will allow creation of `cm::String` instances that borrow from
non-owned storage. It is the caller's responsibility to ensure that
no copy of the instance outlives the borrowed buffer.
|
|
|
|
|
|
| |
Use expression templates to collect the entire expression and
pre-allocate a string with the final length before concatenating
the pieces.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Create a `cm::String` type that holds a view of a string buffer and
optionally shares ownership of the buffer. Instances can either
borrow longer-lived storage (e.g. static storage of string literals)
or internally own a `std::string` instance. In the latter case,
share ownership with copies and substrings. Allocate a new internal
string only on operations that require mutation.
This will allow us to recover string sharing semantics that we
used to get from C++98 std::string copy-on-write implementations.
Such implementations are not allowed by C++11 so code our own in
a custom string type instead.
|
|
|
|
| |
Enable the check in .clang-tidy and fix all warnings.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Found via `codespell -q 3 -I ../cmake-whitelist.txt --skip="./Utilities"`
where the whitelist consists of
```
aci
ans
behaviour
buil
convertor
dum
earch
ect
emmited
emmitted
helpfull
iff
isnt
ith
lowercased
mose
nd
nknown
nto
objext
ot
pathes
pevents
splitted
substract
superceded
supercedes
te
tim
todays
uint
upto
whitespaces
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The documentation for CPack generators previously lived in their
respective internal CMake modules. This setup was misleading,
because it implied that you should include the modules in your own
code, which is not the case. Moving the documentation into a
separate section does a better job of hiding the internal modules,
which are just an implementation detail. The generator documentation
has also been modified to remove any references to the module name.
The CPackIFW module is a special exception: since it has user-facing
macros, the documentation for these macros has been kept in the module
page, while all other documentation related to the IFW generator has
been moved into the new section.
To make it easier to find the new documentation, the old help pages
for the CPack*.cmake modules have not been deleted, but have been
replaced with a link to their respective help page in the new
documentation section.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Run the `clang-format.bash` script to update all our C and C++ code to a
new style defined by `.clang-format`. Use `clang-format` version 6.0.
* If you reached this commit for a line in `git blame`, re-run the blame
operation starting at the parent of this commit to see older history
for the content.
* See the parent commit for instructions to rebase a change across this
style transition commit.
|
|
|
|
|
| |
Render links as the link text only. Render literals as themselves.
This is closer to what the Sphinx text generator does.
|
|
|
|
|
| |
This was accidentally left out of commit 8acf46caf1 (Utilities/Sphinx:
Add role and directive for 'envvar' in CMake domain, 2018-04-19).
|
|
|
|
|
|
|
|
|
|
| |
In commit v2.8.0~170 (ENH: Added ctest test options PROCESSORS and
RUN_SERIAL, 2009-09-07) CTest learned to track the number of processors
allocated to running tests in order to balance it against the desired
level of parallelism. Extend this idea by introducing a new
`PROCESSOR_AFFINITY` test property to ask that CTest run a test
with the CPU affinity mask set. This will allow a set of tests
that are running concurrently to use disjoint CPU resources.
|
| |
|
|
|
|
|
|
|
|
| |
UTF-8 is the proper naming according to the UTF-8 RFC and is also the
name used for a similar keyword in the file() command. This commit
brings (backward compatible) consistency to the keyword names and allows
the standard UTF-8 name to be used with execute_process(). The old UTF8
keyword is still supported.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Fix remaining diagnostics by this lint and remove it from our list of
disabled lints.
|
|\
| |
| |
| |
| |
| |
| |
| |
| | |
ebc91a44 Avoid CRLF newlines in Git repo blobs
c69b4c8d bzip2: Drop unused .dsp files
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Ben Boeckel <ben.boeckel@kitware.com>
Merge-request: !1211
|
| |
| |
| |
| |
| |
| |
| |
| | |
In commit 8ed03baa76 (gitattributes: prefer `eol=crlf` to `-crlf`,
2017-08-23) we left a few CRLF blobs in the repository. Some Git
versions get confused by text files with CRLF blobs. Convert them
to LF blobs. Use the `eol=crlf` attribute to tell Git to use CRLF
on checkout.
|
|\ \
| |/
|/|
| |
| |
| |
| | |
190e3825 Replace C-style casts
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1176
|
| | |
|
|/
|
|
| |
Also remove `#include "cmConfigure.h"` from most source files.
|
|\
| |
| |
| |
| |
| |
| | |
5962db43 Use C++11 nullptr
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1175
|
| | |
|