随笔分类 -  编程语言

c++20 模板约束
摘要:concept 在 c++20 中,提案许久的 concept 被加入到标准中了,这也意味着不用再写恼人的 SFINAE 了(除非你是一个受虐狂,喜欢对着一堆报错中找到错误的位置)。 c++20 之前 在 c++20 之前,如果需要对模板实参进行编译期检查,只能使用 SFINAE ,或者是部分使用
59
0
0
Copy and Swap
摘要:Copy and Swap 在 c++ 中,什么是 copy and swap ? struct Foo { Foo() { std::cout << "Foo construct\n"; } Foo(const Foo &) { std::cout << "Foo copy construct\n
8
0
0
实现一个 std::optional
摘要:实现一个 std::optional 如果写过 c# 或者是 rust ,那么对于里面的可空类型一定是很常用的。在 c++17 中添加了 std::optional ,也就是所谓的可空类型。 不过这里的实现是 placement new 的方式,也是位于栈上。 实现的主要点是申请一块内存空间,由于需
22
0
0
实现一个简单的 std::unique_ptr
摘要:实现一个简单的 std::unique_ptr 简介 std::unique_ptr 是一个独占资源所有权的智能指针,通过 RAII 来自动管理资源的构造和析构。 在标准库中,std::unique_ptr 的通常实现是具有空基类优化。具体来讲,对于 std::unique_ptr 的删除器是其类型
26
0
0
c++ 中的左右值
摘要:c++ 中的左右值 前言:最近又需要再次复习一下关于 c++ 中 lvaue 和 rvalue 相关的知识。 左值和右值 简单看 int a = 1; 这条语句,对于左边的 a ,我们是可以对其取地址的,而对于右边的 1 来说,我们无法对其去地址。 对于能够取地址的 a ,位于=左边,我们就将其称之
60
0
0
点击右上角即可分享
微信分享提示
深色
回顶
收起
  1. 1 Scarborough Fair 山田タマル
  2. 2 Faster Than Light Paradox Interactive,Andreas Waldetoft
  3. 3 世界は可愛く出来ている 上海アリス幻樂団
Scarborough Fair - 山田タマル
00:00 / 00:00
An audio error has occurred, player will skip forward in 2 seconds.

作词 : Pual Simon

作曲 : Pual Simon

作词 : イングランド民謡

作曲:加藤达也

Are you going to Scarborough Fair?

Parsley, sage, rosemary and thyme

Remember me to one who lives there

He once was a true love of mine

Tell him to make me a cambric shirt

Tell him to make me a cambric shirt

Parsley, sage, rosemary and thyme

Without no seams nor needlework

Then he'll be a true love of mine.

Tell him to find me an acre of land

Tell him to find me an acre of land

Parsley, sage, rosemary and thyme

Between the salt water and the sea strand

Then he'll be a true love of mine

Are you going to Scarborough Fair?