Граф коммитов

2243 Коммитов

Автор SHA1 Сообщение Дата
Billy O'Neal 0d95d86ee7
Add back the missing unique_ptr swap (#170)
Resolves DevCom-754487 / VSO-1000729
2019-10-11 14:39:53 -07:00
Stephan T. Lavavej 712b7971bd
Update comments to follow custom autolink syntax (#168)
* Use custom autolinks.

* Also update .clang-format.

* Use ArchivedOS.
2019-10-11 13:43:06 -07:00
Casey Carter f565496875
Workaround clang __is_base_of bug in <type_traits> (#167)
Clang's `__is_base_of` intrinsic incorrectly handles some corner cases involving incomplete union types before LLVM 9. Workaround by guarding with `__is_class`.
2019-10-09 18:21:10 -07:00
Billy O'Neal 9b2207c14e
Parallelize enforcement of clang-format (#163)
Add jobify.exe and parallelize.exe
Add a "tools" directory for test/build support tools.
Add jobify.exe from the msvc repo.
Extract parts of jobify into stljobs.h, and author wrappers for other test support.
Add parallelize.exe which runs a command in parallel over all inputs in a directory.
Teach Azure DevOps to enforce clang-format in parallel.
2019-10-08 17:12:08 -07:00
Bhumij Gupta cd8fee0320 * Replaced Microsoft/STL with microsoft/STL (#157)
* Capitalised first letter of every word in header
2019-10-03 19:17:37 -07:00
Stephan T. Lavavej b72c0a609f
Activate FrameHandler4 to fix #118. (#154)
This affects the x64 build. Before this change, msvcp140.dll
was 601,600 bytes. After this change, it's 540,672 bytes.

This ports a Microsoft-internal PR:
https://devdiv.visualstudio.com/DevDiv/_git/msvc/pullrequest/204636
2019-10-02 15:17:25 -07:00
Stephan T. Lavavej 50f343b458
Implement LWG 3268's PR to fix #150. (#151)
This is a back-compat fix for users who were saying things like
`std::memory_order::memory_order_relaxed`. As there is nothing
especially problematic about such usage, and LWG's ultimate resolution
is unknown, I'm not deprecating these enumerators at this time. If and
when this is voted into the WP in the deprecated clause, then we can
add deprecated attributes.

This mirrors a Microsoft-internal PR:
https://devdiv.visualstudio.com/DevDiv/_git/msvc/pullrequest/205250
2019-10-01 16:04:24 -07:00
rithikmali 4b84225ae0 Corrected URI to URL (#149)
On line 157,corrected URI to URL
2019-10-01 15:44:42 -07:00
Stephan T. Lavavej a1273b8907
Update the PR template to fix #117. (#152)
Update the PR template to fix #117.

This adds a checkbox to the PR template mentioning
license discipline.

It clarifies the instructions regarding unchecked
and inapplicable boxes.

It fuses the "acceptance will be delayed" disclaimer
into the README checkbox.

This also rewraps the issue template (we usually wrap to 120,
but 80 is friendlier to the issue textbox) and improves the
wording by changing "Alternately" to "Alternatively".
2019-10-01 13:20:08 -07:00
Michael Schellenberger Costa cf55d69c40 P1227R2 Signed std::ssize() (#130)
Fixes #56.
2019-09-26 20:10:40 -07:00
Michael Schellenberger Costa 13fa3d8b0e P1357R1 is_bounded_array, is_unbounded_array (#127)
Fixes #58.
2019-09-26 19:54:23 -07:00
Andrew Fogarty 3ed27b95ce P0439R0 enum class memory_order (#124)
Fixes #17.
2019-09-26 19:51:00 -07:00
Casey Carter 1dcac20d28
Refuse to allow clang to include coroutine headers (#136)
Resolves #105.
2019-09-26 10:45:58 -07:00
Charlie Barto 0281a45229
Move cgmanifest.json (#138)
Fixes #125
2019-09-25 19:32:02 -07:00
Charlie Barto ff7d132b2e
implement P0325R4 to_array (#135) 2019-09-25 19:30:31 -07:00
lukka d7c7691f3a Build in Azure Pipelines with cached vcpkg artifacts (#114) 2019-09-25 19:13:53 -07:00
Billy O'Neal d5c2a9aaaa
Add azure pipelines status badge to readme.md. (#134) 2019-09-24 20:02:28 -07:00
Billy O'Neal a8e13582e9
Set up CI with Azure Pipelines that checks that sources are clang-format'd (#132)
This script runs clang-format on the sources, then runs git status --porcelain on the result, redirected to stderr. If any output goes to stderr, Azure Pipelines marks the build as failed, which enforces that no changes were made to the repo by the clang-format pass.

Resolves #88
2019-09-24 19:19:50 -07:00
Casey Carter 62482a6ddd
Fix regex tokenizing bug (#131)
We skip a non-match character in `regex_iterator::operator++` after a zero-length match to avoid repeat matches, resulting in incorrect behavior when tokenizing with a regex to match the delimiters between tokens.

Fixes [DevCom#733051](https://developercommunity.visualstudio.com/content/problem/733051/splitting-a-string-with-a-regex-returns-seemingly.html).
2019-09-24 15:14:39 -07:00
Billy O'Neal 44720cd5f6
Do size modifications after iterator transfer strategy selection (#129)
This was the cause of the DevCom reported bug:

https://developercommunity.visualstudio.com/content/problem/739698/vc-163-listsplice-bug.html

where we would choose the incorrect strategy to transfer iterators if and only if the number of transferred iterators was exactly half of the container.

This change replicates internal [PR 203902](https://devdiv.visualstudio.com/DevDiv/_git/msvc/pullrequest/203902)
2019-09-24 03:23:13 -07:00
Casey Carter aacdfb522b microsoft/vclibs is the code owner (#123)
....not any particular set of members thereof.
2019-09-23 10:19:12 -07:00
Casey Carter da76ab2d5f
basic_string_view's non-member begin/end should take basic_string_view by value (#119)
... as the working draft requires. Test coverage failed to detect this issue due to [an overload resolution bug in MSVC](https://developercommunity.visualstudio.com/content/problem/739010/overload-resolution-fails-to-select-deleted-overlo.html).

Drive-by: Remove the "accepts rvalues" bit from the comment in `begin` which caused the confusion that gave rise to #104. Hopefully it is now glaringly obvious that `begin` and `end` accept both lvalues and rvalues.

Resolves #104.
2019-09-20 12:39:25 -07:00
practicalswift 7f65140761 Fix typos (#96)
* Fix typos

* Run clang-format on touched files

* Revert clang-format damage
2019-09-17 21:45:12 -06:00
Billy O'Neal ee1ede2c62
Remove VCPKG_TARGET_TRIPLET enforcement. (#101)
Resolves #97.

We used to detect target platform by inspection of VCPKG_TARGET_TRIPLET, but that is no longer necessary. As a result, this enforcement can be removed.
2019-09-17 12:32:55 -06:00
Stephan T. Lavavej 5c725eb3d8
Update pull_request_template.md (#103)
Mention clang-format's version to avoid formatting churn.
2019-09-17 11:06:20 -06:00
Billy O'Neal e94b4e758a Create a CODEOWNERS (#102)
This lets us require an STL maintainer to sign off before merging.

See the documentation for CODEOWNERS at
https://help.github.com/en/articles/about-code-owners
2019-09-17 09:07:26 -07:00
Michał Cichoń c838a6f937 Reflect directory structure of includes in ${PROJECT_BINARY_DIR}/out/inc (#98)
Configured headers were flattened during configuration. This patch
keep original directory structure.

For example without this for 'deque` is replaced by `experimental/deque`.
2019-09-17 08:01:08 -07:00
Casey Carter 92508bed63 Update "old" range types
* `array`, `basic_string`, `basic_string_view`, `valarray`, and `vector` (`span` is not yet implemented) model `contiguous_range` by defining the nested type `iterator_concept` to `contiguous_iterator_tag` in `iterator` and `const_iterator`, and specializing `pointer_traits` for those types (to fulfill `contiguous_iterator`'s `std::to_address` requirement)

* `basic_string_view` (Ditto, no `span` yet) models the exposition-only *`forwarding-range`* concept (which indicates that the validity of iterators is not bound to the lifetime of the range) by defining hidden-friend overloads of `begin` and `end` that accept rvalues

* Drive-by:
  * mark the `_Unfancy` internal helper function `[[nodiscard]]`
  * Remove redundant `_Can_begin` requirement from `std::ranges::_Begin::_Cpo::_Choose`

* Add test coverage to `devcrt/P0896R4_ranges_range_machinery`:
  * tighten up `test_std_container`:
    * `data` and `cdata` reject rvalue arguments since the returned pointer could potentially dangle (`contiguous_range` codepaths were lacking coverage)
    * the `size_type` of a standard container can be other than `std::size_t` when using fancy pointers
    * we should enforce that each container's iterator type models the expected concept
  * Add test coverage to ensure that contiguous standard library containers model `contiguous_range` even when using an "old" fancy pointer type that does not model `contiguous_iterator`
2019-09-15 18:41:16 -07:00
Billy O'Neal 1223fb1d50
Add pull request template. (#92) 2019-09-13 15:40:15 -07:00
Billy O'Neal dbbbb48aef
Create issue templates for the STL repo (#90) 2019-09-13 15:39:50 -07:00
Casey Carter 91d4b8fb89 _Has_class_or_enum_type concept should admit unions
Unions have "class type", despite that `is_class_v` is false for unions. Fixes a bug in which the behavior of `std::ranges::swap` cannot be customized for union types.
2019-09-12 12:16:34 -07:00
Casey Carter fc0ad927e9 Add <ranges>, inadvertently ommitted from #82
I experimented with different methods of preparing the dual checkin PR, and chose the wrong one.
2019-09-11 18:26:05 -07:00
Billy O'Neal 0378e99e62
Add "how to consume" instructions to readme.md (#81) 2019-09-11 17:10:31 -07:00
Casey Carter 6fe5ae883f Suppress warning C4180 STL-wide (#84)
C4180 "qualifier applied to function type has no meaning; ignored" is emitted from `std::remove_reference<T>` when `T` is a function type or reference to such after applying the changes in #82. We could suppress it locally, but the warning is extremely low-value for the STL in general so let's simply suppress it globally.
2019-09-10 20:50:35 -07:00
Billy O'Neal 04cea50320
Implement load(8 bytes) with a 64 bit read on x86 (#87)
This depends on compiler support that will first ship in Visual Studio 2019 16.4, so it's guarded to allow the build to work with current preview releases.

Resolves https://developercommunity.visualstudio.com/content/problem/274938/index.html

Replays VSO PR 199513, this is the last substantial change I hope to do before we can work wholly in GitHub.
2019-09-10 19:46:22 -07:00
Casey Carter c5e2e3f799 Ranges <range> machinery
* Implements a selection of support machinery in `std::ranges` and adds the `<ranges>` header. Primarily consists of the range access customization point objects:
  * `ranges::begin`
  * `ranges::end`
  * `ranges::cbegin`
  * `ranges::cend`
  * `ranges::rbegin`
  * `ranges::rend`
  * `ranges::crbegin`
  * `ranges::crend`
  * `ranges::size`
  * `ranges::empty`
  * `ranges::data`
  * `ranges::cdata`

  and range concepts:

  * `ranges::range`
  * `ranges::output_range`
  * `ranges::input_range`
  * `ranges::forward_range`
  * `ranges::bidirectional_range`
  * `ranges::random_access_range`
  * `ranges::contiguous_range`
  * `ranges::sized_range`
  * `ranges::view`
  * `ranges::common_range`

  and the associated type aliases:

  * `ranges::iterator_t`
  * `ranges::sentinel_t`
  * `ranges::range_value_t`
  * `ranges::range_reference_t`
  * `ranges::range_difference_t`
  * `ranges::range_rvalue_reference_t`

* Adds `<ranges>` - which is mostly empty since the support machinery is defined in `<xutility>` so as to be visible to `<algorithm>`

* Annotates [P0896R4](https://wg21.link/p0896r4) as partially implemented in the "`_HAS_CXX20` directly controls" section of `<yvals_core.h>`.

* Touches `<regex>`, `<set>`, and `<unordered_set>` to add partial specializations of `ranges::enable_view` for `match_results` and `(unordered_)?multi?set` as mandated by the WD to override the heuristic.

* Partially implements [P1474R1 "Helpful pointers for `ContiguousIterator`"](https://wg21.link/p1474r1):
  * Push `pointer_traits` from `<xmemory>` and `to_address` from `<memory>` up into `<xutility>`
  * Add `to_address` expression requirement to `contiguous_iterator` concept, and update `P0896R4_ranges_iterator_machinery` appropriately
  * Implement the changes to `ranges::data` (but not `view_interface` since it isn't yet implemented)

* Drive-by:
  * Simplify the definition of `pointer_traits::_Reftype` by eschewing `add_lvalue_reference_t`.
  * Strengthen `reverse_iterator`'s constructors and `make_reverse_iterator` so `ranges::rbegin` and `ranges::rend` can be `noexcept` in more cases
  * Since we're using `_Rng` as the template parameter name for models of `std::ranges::range`, rename a local variable `_Rng` to `_Generator` in `<random>`
2019-09-09 15:31:26 -07:00
Billy O'Neal ace0f6a53f
Remove need for user to specify triplet, and enable ARM and ARM64 build (#80)
* Remove the need to specify the target architecture by testing CMAKE_CXX_COMPILER_ARCHITECTURE_ID.

This is somewhat fragile because it's documented as an internal-to-cmake variable, but FindBoost.cmake has used it 'effectively forever' so I'm not too concerned.

* Make ARM and ARM64 work, and use CMAKE_CXX_STANDARD_LIBRARIES for kernel32.lib.
2019-09-06 19:23:11 -07:00
Stephan T. Lavavej a2153fe64b
Update README.md. (#79)
This adds a status update for the GitHub issue tags.

Wrap to 120.

Renumber an ordered list (doesn't affect Markdown display).
2019-09-06 17:05:34 -07:00
Billy O'Neal 0b9d3cf416
Flesh out readme.md with build instructions and diagram. (#8) 2019-09-06 16:24:17 -07:00
Billy O'Neal 892f6f580a
Remove incorrect noexcept from _Buyheadnode in <list>. (#77)
Replicates https://devdiv.visualstudio.com/DevDiv/_git/msvc/pullrequest/200975
2019-09-05 21:03:29 -07:00
Billy O'Neal d564bf66f6
Tell Github's linguist tool that our files are C++, including extensionless ones (#21)
Resolves #1
2019-09-05 19:42:03 -07:00
Billy O'Neal cd5aeb7e65
Apply useful CMake changes from the subninja attempt that work on their own (#5)
* Affirmatively set _HAS_OLD_IOSTREAMS_MEMBERS=1 to make intellisense in "Open Folder" happy.

* Use add_library(STATIC) and STATIC_LIBRARY_OPTIONS for implib smashing instead of add_custom_command et al.

* Include headers in some of the generated targets so they show up in "open folder" et al.

* Extract the target architecture from VCPKG_TARGET_TRIPLET.

* Add .vs and out/ to .gitignore as VS's open folder creates these.

* Don't link an exe in try_compile.

* Add CMakeSettings.json to make VS happy.
2019-09-05 12:29:04 -07:00
Stephan T. Lavavej 219514876e Initial commit. 2019-09-04 15:57:56 -07:00