155
155
virtual streambuf* setbuf(char* s, streamsize n);
156
156
157
157
private:
158
- typedef T1 strstate; // \expos
159
- static const strstate allocated; // \expos
158
+ using strstate = T1 ; // \expos
159
+ static const strstate allocated; // \expos
160
160
static const strstate constant; // \expos
161
161
static const strstate dynamic; // \expos
162
162
static const strstate frozen; // \expos
996
996
: public basic_iostream<char> {
997
997
public:
998
998
// Types
999
- typedef char char_type ;
1000
- typedef typename char_traits<char>::int_type int_type;
1001
- typedef typename char_traits<char>::pos_type pos_type;
1002
- typedef typename char_traits<char>::off_type off_type;
999
+ using char_type = char ;
1000
+ using int_type = char_traits<char>::int_type;
1001
+ using pos_type = char_traits<char>::pos_type;
1002
+ using off_type = char_traits<char>::off_type;
1003
1003
1004
1004
// constructors/destructor
1005
1005
strstream();
1150
1150
1151
1151
\indexlibrary {\idxcode {unexpected_handler}}%
1152
1152
\begin {itemdecl }
1153
- typedef void (*unexpected_handler )();
1153
+ using unexpected_handler = void (*)();
1154
1154
\end {itemdecl }
1155
1155
1156
1156
\begin {itemdescr }
1271
1271
To enable old function adaptors to manipulate function objects
1272
1272
that take one or two arguments,
1273
1273
many of the function objects in this standard
1274
- correspondingly provide typedefs
1274
+ correspondingly provide \grammarterm {typedef-name}{s}
1275
1275
\tcode {argument_type} and \tcode {result_type}
1276
1276
for function objects that take one argument and
1277
1277
\tcode {first_argument_type}, \tcode {second_argument_type}, and \tcode {result_type}
@@ -1287,147 +1287,147 @@
1287
1287
\begin {codeblock }
1288
1288
namespace std {
1289
1289
template<class T> struct owner_less<shared_ptr<T> > {
1290
- typedef bool result_type;
1291
- typedef shared_ptr<T> first_argument_type ;
1292
- typedef shared_ptr<T> second_argument_type ;
1290
+ using result_type = bool ;
1291
+ using first_argument_type = shared_ptr<T>;
1292
+ using second_argument_type = shared_ptr<T>;
1293
1293
};
1294
1294
1295
1295
template<class T> struct owner_less<weak_ptr<T> > {
1296
- typedef bool result_type;
1297
- typedef weak_ptr<T> first_argument_type ;
1298
- typedef weak_ptr<T> second_argument_type ;
1296
+ using result_type = bool ;
1297
+ using first_argument_type = weak_ptr<T>;
1298
+ using second_argument_type = weak_ptr<T>;
1299
1299
};
1300
1300
1301
1301
template <class T> class reference_wrapper {
1302
1302
public :
1303
- typedef @ \seebelow@ result_type; // not always defined
1304
- typedef @ \seebelow@ argument_type; // not always defined
1305
- typedef @\seebelow@ first_argument_type; // not always defined
1306
- typedef @\seebelow@ second_argument_type; // not always defined
1303
+ using result_type = @ \seebelow@ ; // not always defined
1304
+ using argument_type = @ \seebelow@ ; // not always defined
1305
+ using first_argument_type = @\seebelow@ ; // not always defined
1306
+ using second_argument_type = @\seebelow@ ; // not always defined
1307
1307
};
1308
1308
1309
1309
template <class T> struct plus {
1310
- typedef T first_argument_type;
1311
- typedef T second_argument_type;
1312
- typedef T result_type;
1310
+ using first_argument_type = T ;
1311
+ using second_argument_type = T ;
1312
+ using result_type = T ;
1313
1313
};
1314
1314
1315
1315
template <class T> struct minus {
1316
- typedef T first_argument_type;
1317
- typedef T second_argument_type;
1318
- typedef T result_type;
1316
+ using first_argument_type = T ;
1317
+ using second_argument_type = T ;
1318
+ using result_type = T ;
1319
1319
};
1320
1320
1321
1321
template <class T> struct multiplies {
1322
- typedef T first_argument_type;
1323
- typedef T second_argument_type;
1324
- typedef T result_type;
1322
+ using first_argument_type = T ;
1323
+ using second_argument_type = T ;
1324
+ using result_type = T ;
1325
1325
};
1326
1326
1327
1327
template <class T> struct divides {
1328
- typedef T first_argument_type;
1329
- typedef T second_argument_type;
1330
- typedef T result_type;
1328
+ using first_argument_type = T ;
1329
+ using second_argument_type = T ;
1330
+ using result_type = T ;
1331
1331
};
1332
1332
1333
1333
template <class T> struct modulus {
1334
- typedef T first_argument_type;
1335
- typedef T second_argument_type;
1336
- typedef T result_type;
1334
+ using first_argument_type = T ;
1335
+ using second_argument_type = T ;
1336
+ using result_type = T ;
1337
1337
};
1338
1338
1339
1339
template <class T> struct negate {
1340
- typedef T argument_type;
1341
- typedef T result_type;
1340
+ using argument_type = T ;
1341
+ using result_type = T ;
1342
1342
};
1343
1343
1344
1344
template <class T> struct equal_to {
1345
- typedef T first_argument_type;
1346
- typedef T second_argument_type;
1347
- typedef bool result_type;
1345
+ using first_argument_type = T ;
1346
+ using second_argument_type = T ;
1347
+ using result_type = bool ;
1348
1348
};
1349
1349
1350
1350
template <class T> struct not_equal_to {
1351
- typedef T first_argument_type;
1352
- typedef T second_argument_type;
1353
- typedef bool result_type;
1351
+ using first_argument_type = T ;
1352
+ using second_argument_type = T ;
1353
+ using result_type = bool ;
1354
1354
};
1355
1355
1356
1356
template <class T> struct greater {
1357
- typedef T first_argument_type;
1358
- typedef T second_argument_type;
1359
- typedef bool result_type;
1357
+ using first_argument_type = T ;
1358
+ using second_argument_type = T ;
1359
+ using result_type = bool ;
1360
1360
};
1361
1361
1362
1362
template <class T> struct less {
1363
- typedef T first_argument_type;
1364
- typedef T second_argument_type;
1365
- typedef bool result_type;
1363
+ using first_argument_type = T ;
1364
+ using second_argument_type = T ;
1365
+ using result_type = bool ;
1366
1366
};
1367
1367
1368
1368
template <class T> struct greater_equal {
1369
- typedef T first_argument_type;
1370
- typedef T second_argument_type;
1371
- typedef bool result_type;
1369
+ using first_argument_type = T ;
1370
+ using second_argument_type = T ;
1371
+ using result_type = bool ;
1372
1372
};
1373
1373
1374
1374
template <class T> struct less_equal {
1375
- typedef T first_argument_type;
1376
- typedef T second_argument_type;
1377
- typedef bool result_type;
1375
+ using first_argument_type = T ;
1376
+ using second_argument_type = T ;
1377
+ using result_type = bool ;
1378
1378
};
1379
1379
1380
1380
template <class T> struct logical_and {
1381
- typedef T first_argument_type;
1382
- typedef T second_argument_type;
1383
- typedef bool result_type;
1381
+ using first_argument_type = T ;
1382
+ using second_argument_type = T ;
1383
+ using result_type = bool ;
1384
1384
};
1385
1385
1386
1386
template <class T> struct logical_or {
1387
- typedef T first_argument_type;
1388
- typedef T second_argument_type;
1389
- typedef bool result_type;
1387
+ using first_argument_type = T ;
1388
+ using second_argument_type = T ;
1389
+ using result_type = bool ;
1390
1390
};
1391
1391
1392
1392
template <class T> struct logical_not {
1393
- typedef T argument_type;
1394
- typedef bool result_type;
1393
+ using argument_type = T ;
1394
+ using result_type = bool ;
1395
1395
};
1396
1396
1397
1397
template <class T> struct bit_and {
1398
- typedef T first_argument_type;
1399
- typedef T second_argument_type;
1400
- typedef T result_type;
1398
+ using first_argument_type = T ;
1399
+ using second_argument_type = T ;
1400
+ using result_type = T ;
1401
1401
};
1402
1402
1403
1403
template <class T> struct bit_or {
1404
- typedef T first_argument_type;
1405
- typedef T second_argument_type;
1406
- typedef T result_type;
1404
+ using first_argument_type = T ;
1405
+ using second_argument_type = T ;
1406
+ using result_type = T ;
1407
1407
};
1408
1408
1409
1409
template <class T> struct bit_xor {
1410
- typedef T first_argument_type;
1411
- typedef T second_argument_type;
1412
- typedef T result_type;
1410
+ using first_argument_type = T ;
1411
+ using second_argument_type = T ;
1412
+ using result_type = T ;
1413
1413
};
1414
1414
1415
1415
template <class T> struct bit_not {
1416
- typedef T argument_type;
1417
- typedef T result_type;
1416
+ using argument_type = T ;
1417
+ using result_type = T ;
1418
1418
};
1419
1419
1420
1420
template<class R, class T1>
1421
1421
class function<R(T1)> {
1422
1422
public:
1423
- typedef T1 argument_type;
1423
+ using argument_type = T1 ;
1424
1424
};
1425
1425
1426
1426
template<class R, class T1, class T2>
1427
1427
class function<R(T1, T2)> {
1428
1428
public:
1429
- typedef T1 first_argument_type;
1430
- typedef T2 second_argument_type;
1429
+ using first_argument_type = T1 ;
1430
+ using second_argument_type = T2 ;
1431
1431
};
1432
1432
}
1433
1433
\end {codeblock }
1525
1525
template <class Key, class T, class Compare, class Allocator>
1526
1526
class map<Key, T, Compare, Allocator>::value_compare {
1527
1527
public:
1528
- typedef bool result_type;
1529
- typedef value_type first_argument_type;
1530
- typedef value_type second_argument_type;
1528
+ using result_type = bool ;
1529
+ using first_argument_type = value_type ;
1530
+ using second_argument_type = value_type ;
1531
1531
};
1532
1532
1533
1533
template <class Key, class T, class Compare, class Allocator>
1534
1534
class multimap<Key, T, Compare, Allocator>::value_compare {
1535
1535
public:
1536
- typedef bool result_type;
1537
- typedef value_type first_argument_type;
1538
- typedef value_type second_argument_type;
1536
+ using result_type = bool ;
1537
+ using first_argument_type = value_type ;
1538
+ using second_argument_type = value_type ;
1539
1539
};
1540
1540
}
1541
1541
\end {codeblock }
1568
1568
public:
1569
1569
constexpr explicit unary_negate(const Predicate& pred);
1570
1570
constexpr bool operator()(const typename Predicate::argument_type& x) const;
1571
- typedef typename Predicate::argument_type argument_type;
1572
- typedef bool result_type;
1571
+ using argument_type = typename Predicate::argument_type;
1572
+ using result_type = bool ;
1573
1573
};
1574
1574
\end {codeblock }
1575
1575
1600
1600
constexpr explicit binary_negate(const Predicate& pred);
1601
1601
constexpr bool operator()(const typename Predicate::first_argument_type& x,
1602
1602
const typename Predicate::second_argument_type& y) const;
1603
- typedef typename Predicate::first_argument_type first_argument_type;
1604
- typedef typename Predicate::second_argument_type second_argument_type;
1605
- typedef bool result_type;
1603
+ using first_argument_type = typename Predicate::first_argument_type;
1604
+ using second_argument_type = typename Predicate::second_argument_type;
1605
+ using result_type = bool;
1606
+
1606
1607
};
1607
1608
\end {codeblock }
1608
1609
0 commit comments