摘要: 在 C++ 中分配一个未初始化内存,然后读取它,会读取到这块内存之前被使用所留下的值,这种现象我称之为 flashback。 栈内存很容易出现这种现象,而且很容易观测出某种规律。 for (int i = 0; i < 10; ++i) { int a; std::cout << a << " "; 阅读全文
posted @ 2021-12-22 09:09 mkckr0 阅读(276) 评论(0) 推荐(0) 编辑
摘要: 如果网卡1是 NAT,网卡2是 Host-Only,可以 ping 通 baidu.com。 如果网卡1是 Host-Only,网卡2是 NAT,无法 ping 通 baidu.com。 使用 nmcli 修改 NAT 网卡和 Host-Only 网卡的 ipv4.route-metric,分别设置 阅读全文
posted @ 2021-12-22 07:29 mkckr0 阅读(259) 评论(0) 推荐(0) 编辑
摘要: P0668R4 对此进行了解释 The definition of plain happens-before became unpleasantly complicated with the introduction of memory_order_consume. And it is not tr 阅读全文
posted @ 2021-12-22 06:53 mkckr0 阅读(323) 评论(0) 推荐(0) 编辑
摘要: 操作系统设置会影响浏览器的行为 Win+R 输入 sysdm.cpl ,3 打开 性能 的 设置 确保 窗口内动画控件和元素 被勾选 阅读全文
posted @ 2021-12-22 00:30 mkckr0 阅读(102) 评论(0) 推荐(0) 编辑
摘要: 每次提交使用 git commit --allow-empty-message --no-edit 也可以设置命令别名 git config --global alias.nocommit "commit --allow-empty-message --no-edit" git nocommit 阅读全文
posted @ 2021-12-22 00:23 mkckr0 阅读(268) 评论(0) 推荐(0) 编辑