Skip to content

Commit

Permalink
Merge pull request #42 from prehistoric-penguin/fix-39
Browse files Browse the repository at this point in the history
Fix #39
  • Loading branch information
jeaye authored Nov 17, 2020
2 parents d1961bc + a035046 commit 478d353
Show file tree
Hide file tree
Showing 5,949 changed files with 100,201 additions and 97,708 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ make generate # will build stdman and generate man pages
**NOTE**: `make generate` expects sources will be in the `./reference/en/cpp` directory by default. See `./configure --help` to modify this.

### Compilation/Generation Dependencies
* C++11 (recommended GCC 4.8 or clang 3.4 or greater)
* C++11 (recommended GCC 4.9 or clang 3.4 or greater)
* elinks (recommended 0.12pre6 or greater)
* gzip (recommended 1.3.12 or greater)

Expand Down
21 changes: 11 additions & 10 deletions man/Deductionguidesforstd::chrono::zoned_time.3
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH Deductionguidesforstd::chrono::zoned_time 3 "2019.08.27" "http://cppreference.com" "C++ Standard Libary"
.TH Deductionguidesforstd::chrono::zoned_time 3 "2020.11.17" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
Deductionguidesforstd::chrono::zoned_time \- Deductionguidesforstd::chrono::zoned_time

Expand All @@ -8,32 +8,33 @@ Deductionguidesforstd::chrono::zoned_time \- Deductionguidesforstd::chrono::zone

zoned_time(std::chrono::sys_time<Duration>) \fB(2)\fP \fI(since C++20)\fP

-> zoned_time<std::common_type_t<Duration, std::chrono::seconds>>;
-> zoned_time<std::common_type_t<Duration,
std::chrono::seconds>>;
template< class TimeZonePtrOrName >
zoned_time(TimeZonePtrOrName) -> zoned_time<std::chrono::seconds, \fB(3)\fP \fI(since C++20)\fP
/* see below */>;
template< class TimeZonePtrOrName, class Duration >

zoned_time(TimeZonePtrOrName, std::chrono::sys_time<Duration>) \fB(4)\fP \fI(since C++20)\fP

-> zoned_time<std::common_type_t<Duration, std::chrono::seconds>,
/* see below */>;
-> zoned_time<std::common_type_t<Duration,
std::chrono::seconds>, /* see below */>;
template< class TimeZonePtrOrName, class Duration >

zoned_time(TimeZonePtrOrName, std::chrono::local_time<Duration>,
std::chrono::choose = std::chrono::choose::earliest) \fB(5)\fP \fI(since C++20)\fP
std::chrono::choose = std::chrono::choose::earliest) \fB(5)\fP \fI(since C++20)\fP

-> zoned_time<std::common_type_t<Duration, std::chrono::seconds>,
/* see below */>;
-> zoned_time<std::common_type_t<Duration,
std::chrono::seconds>, /* see below */>;
template< class TimeZonePtrOrName, class Duration, class
TimeZonePtr2 >

zoned_time(TimeZonePtrOrName, std::chrono::zoned_time<Duration,
TimeZonePtr2>, \fB(6)\fP \fI(since C++20)\fP
std::chrono::choose = std::chrono::choose::earliest)
std::chrono::choose = std::chrono::choose::earliest)

-> zoned_time<std::common_type_t<Duration, std::chrono::seconds>,
/* see below */>;
-> zoned_time<std::common_type_t<Duration,
std::chrono::seconds>, /* see below */>;

Six deduction guides are provided for zoned_time. They normalize Duration to a
minimum resolution of std::chrono::seconds, and provide correct handling for time
Expand Down
2 changes: 1 addition & 1 deletion man/begin,end(std::basic_string_view).3
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH begin,end(std::basic_string_view) 3 "2019.08.27" "http://cppreference.com" "C++ Standard Libary"
.TH begin,end(std::basic_string_view) 3 "2020.11.17" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
begin,end(std::basic_string_view) \- begin,end(std::basic_string_view)

Expand Down
2 changes: 1 addition & 1 deletion man/begin,end(std::span).3
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH begin,end(std::span) 3 "2019.08.27" "http://cppreference.com" "C++ Standard Libary"
.TH begin,end(std::span) 3 "2020.11.17" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
begin,end(std::span) \- begin,end(std::span)

Expand Down
4 changes: 2 additions & 2 deletions man/deductionguidesforstd::array.3
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH deductionguidesforstd::array 3 "2019.08.27" "http://cppreference.com" "C++ Standard Libary"
.TH deductionguidesforstd::array 3 "2020.11.17" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
deductionguidesforstd::array \- deductionguidesforstd::array

Expand All @@ -23,6 +23,6 @@ deductionguidesforstd::array \- deductionguidesforstd::array
{
int const x = 10;
std::array a{1, 2, 3, 5, x}; // OK, creates std::array<int, 5>

// std::array b{1, 2u}; // Error, all arguments must have same type
}
4 changes: 2 additions & 2 deletions man/deductionguidesforstd::basic_regex.3
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH deductionguidesforstd::basic_regex 3 "2019.08.27" "http://cppreference.com" "C++ Standard Libary"
.TH deductionguidesforstd::basic_regex 3 "2020.11.17" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
deductionguidesforstd::basic_regex \- deductionguidesforstd::basic_regex

Expand All @@ -7,7 +7,7 @@ deductionguidesforstd::basic_regex \- deductionguidesforstd::basic_regex
template<class ForwardIt>

basic_regex(ForwardIt, ForwardIt,
std::regex_constants::syntax_option_type = \fI(since C++17)\fP
std::regex_constants::syntax_option_type = \fI(since C++17)\fP
std::regex_constants::ECMAScript)

-> basic_regex<typename std::iterator_traits<ForwardIt>::value_type>;
Expand Down
24 changes: 13 additions & 11 deletions man/deductionguidesforstd::basic_string.3
Original file line number Diff line number Diff line change
@@ -1,36 +1,38 @@
.TH deductionguidesforstd::basic_string 3 "2019.08.27" "http://cppreference.com" "C++ Standard Libary"
.TH deductionguidesforstd::basic_string 3 "2020.11.17" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
deductionguidesforstd::basic_string \- deductionguidesforstd::basic_string

.SH Synopsis
Defined in header <string>
template<class InputIt, class Alloc = std::allocator<

typename std::iterator_traits<InputIt>::value_type>>
typename
std::iterator_traits<InputIt>::value_type>>
basic_string(InputIt, InputIt, Alloc = Alloc())
-> basic_string<typename \fB(1)\fP \fI(since C++17)\fP
std::iterator_traits<InputIt>::value_type,
std::char_traits<typename
std::char_traits<typename
std::iterator_traits<InputIt>::value_type>,

Alloc>;
Alloc>;
template<class CharT,

class Traits,
class Alloc = std::allocator<CharT>> \fB(2)\fP \fI(since C++17)\fP
class Traits,
class Alloc = std::allocator<CharT>> \fB(2)\fP \fI(since C++17)\fP
explicit basic_string(std::basic_string_view<CharT, Traits>, const
Alloc& = Alloc())

-> basic_string<CharT, Traits, Alloc>;
template<class CharT,

class Traits,
class Alloc = std::allocator<CharT>>>
class Traits,
class Alloc = std::allocator<CharT>>>
basic_string(std::basic_string_view<CharT, Traits>, typename /*see \fB(3)\fP \fI(since C++17)\fP
below*/::size_type,
typename /*see below*/::size_type, const Alloc& = Alloc())
typename /*see below*/::size_type, const Alloc& =
Alloc())

-> basic_string<CharT, Traits, Alloc>;
-> basic_string<CharT, Traits, Alloc>;

1) This deduction guide is provided for std::basic_string to allow deduction from an
iterator range. This overload only participates in overload resolution if InputIt
Expand All @@ -54,7 +56,7 @@ deductionguidesforstd::basic_string \- deductionguidesforstd::basic_string
std::basic_string_views are made templates to avoid causing ambiguities in existing
code, and those templates do not support class template argument deduction.

Defect reports
Defect reports

The following behavior-changing defect reports were applied retroactively to
previously published C++ standards.
Expand Down
11 changes: 6 additions & 5 deletions man/deductionguidesforstd::deque.3
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
.TH deductionguidesforstd::deque 3 "2019.08.27" "http://cppreference.com" "C++ Standard Libary"
.TH deductionguidesforstd::deque 3 "2020.11.17" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
deductionguidesforstd::deque \- deductionguidesforstd::deque

.SH Synopsis
Defined in header <deque>
template< class InputIt,

class Alloc = std::allocator<typename
class Alloc = std::allocator<typename
std::iterator_traits<InputIt>::value_type>> \fI(since C++17)\fP
deque(InputIt, InputIt, Alloc = Alloc())

-> deque<typename std::iterator_traits<InputIt>::value_type, Alloc>;
-> deque<typename std::iterator_traits<InputIt>::value_type,
Alloc>;

This deduction guide is provided for deque to allow deduction from an iterator
range. This overload only participates in overload resolution if InputIt satisfies
Expand All @@ -33,10 +34,10 @@ deductionguidesforstd::deque \- deductionguidesforstd::deque
#include <vector>
int main() {
std::vector<int> v = {1, 2, 3, 4};

// uses explicit deduction guide to deduce std::deque<int>
std::deque x(v.begin(), v.end());

// deduces std::deque<std::vector<int>::iterator>
// first phase of overload resolution for list-initialization selects the candidate
// synthesized from the initializer-list constructor; second phase is not performed and
Expand Down
10 changes: 5 additions & 5 deletions man/deductionguidesforstd::forward_list.3
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
.TH deductionguidesforstd::forward_list 3 "2019.08.27" "http://cppreference.com" "C++ Standard Libary"
.TH deductionguidesforstd::forward_list 3 "2020.11.17" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
deductionguidesforstd::forward_list \- deductionguidesforstd::forward_list

.SH Synopsis
Defined in header <forward_list>
template< class InputIt,

class Alloc = std::allocator<typename
class Alloc = std::allocator<typename
std::iterator_traits<InputIt>::value_type>> \fI(since C++17)\fP
forward_list(InputIt, InputIt, Alloc = Alloc())

-> forward_list<typename std::iterator_traits<InputIt>::value_type,
-> forward_list<typename std::iterator_traits<InputIt>::value_type,
Alloc>;

This deduction guide is provided for forward_list to allow deduction from an
Expand All @@ -34,10 +34,10 @@ deductionguidesforstd::forward_list \- deductionguidesforstd::forward_list
#include <vector>
int main() {
std::vector<int> v = {1, 2, 3, 4};

// uses explicit deduction guide to deduce std::forward_list<int>
std::forward_list x(v.begin(), v.end());

// deduces std::forward_list<std::vector<int>::iterator>
// first phase of overload resolution for list-initialization selects the candidate
// synthesized from the initializer-list constructor; second phase is not performed and
Expand Down
2 changes: 1 addition & 1 deletion man/deductionguidesforstd::function.3
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH deductionguidesforstd::function 3 "2019.08.27" "http://cppreference.com" "C++ Standard Libary"
.TH deductionguidesforstd::function 3 "2020.11.17" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
deductionguidesforstd::function \- deductionguidesforstd::function

Expand Down
10 changes: 5 additions & 5 deletions man/deductionguidesforstd::list.3
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
.TH deductionguidesforstd::list 3 "2019.08.27" "http://cppreference.com" "C++ Standard Libary"
.TH deductionguidesforstd::list 3 "2020.11.17" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
deductionguidesforstd::list \- deductionguidesforstd::list

.SH Synopsis
Defined in header <list>
template< class InputIt,

class Alloc = std::allocator<typename
class Alloc = std::allocator<typename
std::iterator_traits<InputIt>::value_type>> \fI(since C++17)\fP
list(InputIt, InputIt, Alloc = Alloc())

-> list<typename std::iterator_traits<InputIt>::value_type, Alloc>;
-> list<typename std::iterator_traits<InputIt>::value_type, Alloc>;

This deduction guide is provided for list to allow deduction from an iterator range.
This overload only participates in overload resolution if InputIt satisfies
Expand All @@ -33,10 +33,10 @@ deductionguidesforstd::list \- deductionguidesforstd::list
#include <vector>
int main() {
std::vector<int> v = {1, 2, 3, 4};

// uses explicit deduction guide to deduce std::list<int>
std::list x(v.begin(), v.end());

// deduces std::list<std::vector<int>::iterator>
// first phase of overload resolution for list-initialization selects the candidate
// synthesized from the initializer-list constructor; second phase is not performed and
Expand Down
37 changes: 19 additions & 18 deletions man/deductionguidesforstd::map.3
Original file line number Diff line number Diff line change
@@ -1,54 +1,55 @@
.TH deductionguidesforstd::map 3 "2019.08.27" "http://cppreference.com" "C++ Standard Libary"
.TH deductionguidesforstd::map 3 "2020.11.17" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
deductionguidesforstd::map \- deductionguidesforstd::map

.SH Synopsis
Defined in header <map>
template <class InputIt,

class Comp = std::less<iter_key_t<InputIt>>,
class Alloc = std::allocator<iter_to_alloc_t<InputIt>>> \fB(1)\fP \fI(since C++17)\fP
class Comp = std::less<iter_key_t<InputIt>>,
class Alloc = std::allocator<iter_to_alloc_t<InputIt>>> \fB(1)\fP \fI(since C++17)\fP
map(InputIt, InputIt, Comp = Comp(), Alloc = Alloc())

-> map<iter_key_t<InputIt>, iter_val_t<InputIt>, Comp, Alloc>;
-> map<iter_key_t<InputIt>, iter_val_t<InputIt>, Comp, Alloc>;
template<class Key,

class T,
class Comp = std::less<Key>,
class Alloc = std::allocator<std::pair<const Key, T>>> \fB(2)\fP \fI(since C++17)\fP
class T,
class Comp = std::less<Key>,
class Alloc = std::allocator<std::pair<const Key, T>>> \fB(2)\fP \fI(since C++17)\fP
map(std::initializer_list<std::pair<Key, T>>, Comp = Comp(), Alloc
= Alloc())

-> map<Key, T, Comp, Alloc>;
-> map<Key, T, Comp, Alloc>;
template<class InputIt, class Alloc>

map(InputIt, InputIt, Alloc) \fB(3)\fP \fI(since C++17)\fP
-> map<iter_key_t<InputIt>, iter_val_t<InputIt>,
-> map<iter_key_t<InputIt>, iter_val_t<InputIt>,

std::less<iter_key_t<InputIt>>, Alloc>;
std::less<iter_key_t<InputIt>>, Alloc>;
template<class Key, class T, class Allocator>

map(std::initializer_list<std::pair<Key, T>>, Allocator) \fB(4)\fP \fI(since C++17)\fP

-> map<Key, T, std::less<Key>, Allocator>;
-> map<Key, T, std::less<Key>, Allocator>;

where the type aliases iter_key_t, iter_val_t, iter_to_alloc_t are defined as if as
follows

template<class InputIt>
(exposition
using iter_key_t = std::remove_const_t< only)

typename std::iterator_traits<InputIt>::value_type::first_type>;
using iter_key_t = std::remove_const_t< (exposition
only)
typename
std::iterator_traits<InputIt>::value_type::first_type>;
template<class InputIt> (exposition
using iter_val_t = typename only)
std::iterator_traits<InputIt>::value_type::second_type;
template<class InputIt>

using iter_to_alloc_t = std::pair<
std::add_const_t<typename (exposition
std::add_const_t<typename (exposition
std::iterator_traits<InputIt>::value_type::first_type>, only)
typename std::iterator_traits<InputIt>::value_type::second_type
typename std::iterator_traits<InputIt>::value_type::second_type

>

Expand All @@ -75,12 +76,12 @@ deductionguidesforstd::map \- deductionguidesforstd::map
// std::map m1 = {{"foo", 1}, {"bar", 2}}; // Error: braced-init-list has no type;
// cannot deduce pair<Key, T> from
// {"foo", 1} or {"bar", 2}

std::map m1 = {std::pair{"foo", 2}, {"bar", 3}}; // guide #2
std::map m2(m1.begin(), m1.end()); // guide #1
}

Defect reports
Defect reports

The following behavior-changing defect reports were applied retroactively to
previously published C++ standards.
Expand Down
Loading

0 comments on commit 478d353

Please sign in to comment.