Commit Graph

8 Commits

Author SHA1 Message Date
Xi Ge
a644ab33a0 swift-api-digester: fix recently found false positives. (#8899)
* swift-api-digester: ensure constructors are detected as removed if not moved. rdar://31694119

* swift-api-digester: types with the same printed name are considered behavior-preserving. rdar://31694085

* [test] Using tmp directory from build.
2017-04-20 18:34:52 -07:00
Maxim Moiseev
dd2ad785cd Removing the tmp folder even when api-stability test fails (#8785) 2017-04-16 09:40:25 -07:00
Xi Ge
583da52348 swift-api-digester: re-enable swift-api-digester tests after fixing a release-only failure. rdar://29591753 (#6276) 2016-12-14 17:00:24 -08:00
Xi Ge
d3b5dfa8d9 Revert "swift-api-digester: initialize vector with a reasonable capacity." (#6184)
This did not resolve the test failure.
2016-12-09 18:39:29 -08:00
Xi Ge
e6dcd443eb swift-api-digester: initialize vector with a reasonable capacity.
In Jenkins bot, we've seen "exception std::length_error: vector" for
api-digester tests. Tentatively, this patch initializes a major vector with a
reasonably large size, which may avoid its wild capacity growth.
2016-12-09 16:45:18 -08:00
Xi Ge
73bd3526ca [test] Disable failing api-digester test while investigating. (#6166) 2016-12-09 11:15:56 -08:00
Michael Ilseman
12efcc9db6 [Version] Don't allow effective sub-versions, only major versions
Also offer a note when the major version is valid on its own.
2016-10-18 14:43:21 -07:00
Xi Ge
452ebbc6eb [Tools] Add a tool to detect source-breaking API changes introduced from libraries. (#5236)
[Tools] Add a tool to detect source-breaking API changes introduced from libraries.

swift-api-digester is a test utility to detect source-breaking API changes
during the evolution of a swift library. The tool works on two phases:
(1) dumping library contents as a json file, and (2) comparing two json
files textually to report interesting changes.

During phase (1), the api-digester looks up every declarations inside
a module and outputs a singly-rooted tree that encloses interesting
details of the API level.

During phase (2), api-digester applies structure-information comparision
algorithms on two given singly root trees, trying to figure out, as
precise as possible, the branches/leaves in the trees that differ from
each other. Further analysis decides whether the changed leaves/branches
can be reflected as source-breaking changes for API users. If they are,
the output of api-digester will include such changes.

Also, this commit includes a regression test that make sure API changes
from the Swift stdlib are expected.
2016-10-11 19:43:01 -07:00