Skip to content

Commit 3999a2e

Browse files
authored
Merge pull request #427 from swiftwasm/master
[pull] swiftwasm from master
2 parents 00fadc0 + ba78dbb commit 3999a2e

File tree

2 files changed

+17
-1
lines changed

2 files changed

+17
-1
lines changed

docs/Testing.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,22 @@ test suite, via ``utils/build-script --validation-test``.
4949
Using ``utils/build-script`` will rebuild all targets which can add substantial
5050
time to a debug cycle.
5151

52+
#### Using utils/run-test
53+
54+
Using `utils/run-test` allows the user to run a single test or tests in a specific directory.
55+
This can significantly speed up the debug cycle. One can use this tool
56+
instead of invoking `lit.py` directly as described in the next section.
57+
58+
Here is an example of running the `test/Parse` tests:
59+
```
60+
% ${swift_SOURCE_ROOT}/utils/run-test --build-dir ${SWIFT_BUILD_DIR} ${swift_SOURCE_ROOT}/test/Parse
61+
```
62+
Note that one example of a valid `${SWIFT_BUILD_DIR}` is
63+
`{swift_SOURCE_ROOT}/../build/Ninja-DebugAssert/swift-linux-x86_64`.
64+
It differs based on your build options and on which directory you invoke the script from.
65+
66+
For full help options, pass `-h` to `utils/run-test` utility.
67+
5268
#### Using lit.py
5369

5470
Using `lit.py` directly can provide more control and faster feedback to your

lib/ClangImporter/ImportDecl.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7680,7 +7680,7 @@ void ClangImporter::Implementation::importAttributes(
76807680
// Ban CFRelease|CFRetain|CFAutorelease(CFTypeRef) as well as custom ones
76817681
// such as CGColorRelease(CGColorRef).
76827682
if (auto FD = dyn_cast<clang::FunctionDecl>(ClangDecl)) {
7683-
if (FD->getNumParams() == 1 &&
7683+
if (FD->getNumParams() == 1 && FD->getDeclName().isIdentifier() &&
76847684
(FD->getName().endswith("Release") ||
76857685
FD->getName().endswith("Retain") ||
76867686
FD->getName().endswith("Autorelease")) &&

0 commit comments

Comments
 (0)