Kho tháng 12/2017
Thu Dec 28 08:03:44 +07 2017
c++11 language features and standard library
Extract from The C++ Programming Language, forth edition. Chapter 1.4.4.1 with some more from 44.2 and a bit from c++14
- Control of defauls with
=delete
and=default
- Type deduction with
auto
anddecltype()
- Compile-time evaluation with
constexpr
andstatic_assert()
- In-class member initializers
- Inheriting constructors
- Lambda expressions (and suffix return type), nice to go with
for_each()
and other std::algorithms. - Move semantics and
std::move()
noexcept
and[[noreturn]]
(c++14 adds[[deprecated]]
; c++17 adds[[fallthrough]]
,[[maybe_unsused]]
and[[nodiscard]]
)nullptr
instead of the C way "NULL"for
with a rangestd::begin()
andstd::end()
(c++14 addsstd::cbegin()
andstd::cend()
to use withauto
)- Override controls with
final
andoverride
- Type alias with
using
- Typed enum with
enum class
- Initializer syntax
{}
andstd::initializer_list
>>
and template declaration (thanks God!)- Raw string literals
R"()"
and user-defined literals (c++14 standardizes string and time suffixes). Also binary literal prefix '0b' and digit separators in c++14. - Declarations in conditions (probably since c++90, c++17 allows multiple declarations)
- Nested namespace declaration in c++17 (too far away)
Extract from 1.4.4.2
- hash map with
unordered_map<>
async()
and friends- regular expression
unique_ptr<>
andshared_ptr<>
(bye byeauto_ptr<>
). c++14 addsstd::make_unique<>()
std::function<>
andstd::bind()
-
std::array<>
rethrow_exception()
andnested_exception
emplace()
in STLstd::quoted
on iostreams might be a nice addition (in c++14)- c++17 finally has a file system library, wow.
- c++17 also adds
std::variant<>
, which sounds nice.
Thứ tư, 27 Tháng mười hai năm 2017 18:19:36 ICT
Xem "cây tiến trình" của một tiến trình, v.d. shell hiện tại
pstree -s $$
Hiện pid luôn thì thực tế hơn miếng
pstree -ps $$
pstree -h
không chừng sẽ hữu dụng hơn nếu có thể đổi màu highlight.
Thứ hai, 25 Tháng mười hai năm 2017 17:48:14 ICT
Intel sna làm cho emacs vẽ lỗ chỗ, chuyển qua dùng uxa có vẻ hết
Fri Dec 22 12:35:39 +07 2017
Old, friendly and dead names
One of the things we did not foresee in 2017 is the sad demise of Linux Journal, which has been covering our community since the earliest days. That publication joins a long list of others --- The H, NewsForge, KernelTrap, LinuxWorld, Kernel Traffic, NTK, Linux Gazette, RootPrompt, Linux Action Show, LinuxDevices, Linux Voice, and so on --- that are no longer active.
https://lwn.net/Articles/741462/
Chủ nhật, 17 Tháng mười hai năm 2017 19:43:10 ICT
26 hours in Divinity: Original Sin and I... went back to finish the tutorial
Cập nhật 1 lần. Lần cuối: Fri Aug 26 00:20:24+0003 2022