summaryrefslogtreecommitdiffhomepage
path: root/vhosts/blog/content/posts/2021-10-02
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2025-05-06 16:12:27 +0900
committernsfisis <nsfisis@gmail.com>2025-05-06 16:12:27 +0900
commit21136ab8db7572c527726f93009b4b72bf00f9a9 (patch)
tree34805d49d55af7ac58e5b87d224de43fb7819c73 /vhosts/blog/content/posts/2021-10-02
parent83c58924bfd9f22ef4ff84fd3439535e4753ec53 (diff)
downloadnsfisis.dev-21136ab8db7572c527726f93009b4b72bf00f9a9.tar.gz
nsfisis.dev-21136ab8db7572c527726f93009b4b72bf00f9a9.tar.zst
nsfisis.dev-21136ab8db7572c527726f93009b4b72bf00f9a9.zip
feat(blog/nuldoc): implement codeblock filename
Diffstat (limited to 'vhosts/blog/content/posts/2021-10-02')
-rw-r--r--vhosts/blog/content/posts/2021-10-02/ruby-detect-running-implementation.dj1
-rw-r--r--vhosts/blog/content/posts/2021-10-02/ruby-then-keyword-and-case-in.dj1
-rw-r--r--vhosts/blog/content/posts/2021-10-02/rust-where-are-primitive-types-from.dj1
-rw-r--r--vhosts/blog/content/posts/2021-10-02/vim-difference-between-autocmd-bufwrite-and-bufwritepre.dj5
4 files changed, 8 insertions, 0 deletions
diff --git a/vhosts/blog/content/posts/2021-10-02/ruby-detect-running-implementation.dj b/vhosts/blog/content/posts/2021-10-02/ruby-detect-running-implementation.dj
index 4c73580c..653b7dcd 100644
--- a/vhosts/blog/content/posts/2021-10-02/ruby-detect-running-implementation.dj
+++ b/vhosts/blog/content/posts/2021-10-02/ruby-detect-running-implementation.dj
@@ -65,6 +65,7 @@ CRuby) については執筆時現在 (2020/12/8) も `'ruby'`
[mruby 該当部分のソース](https://github.com/mruby/mruby/blob/ed29d74bfd95362eaeb946fcf7e865d80346b62b/include/mruby/version.h#L32-L35) より引用:
+{filename="version.h"}
```c
/*
* Ruby engine.
diff --git a/vhosts/blog/content/posts/2021-10-02/ruby-then-keyword-and-case-in.dj b/vhosts/blog/content/posts/2021-10-02/ruby-then-keyword-and-case-in.dj
index 7d8616fc..82d6d9cc 100644
--- a/vhosts/blog/content/posts/2021-10-02/ruby-then-keyword-and-case-in.dj
+++ b/vhosts/blog/content/posts/2021-10-02/ruby-then-keyword-and-case-in.dj
@@ -143,6 +143,7 @@ Ruby の場合、プログラマーが書きやすいよう改行でもって `t
https://github.com/ruby/ruby/blob/221ca0f8281d39f0dfdfe13b2448875384bbf735/parse.y#L3961-L3986
+{filename="parse.y"}
```yacc
p_case_body : keyword_in
{
diff --git a/vhosts/blog/content/posts/2021-10-02/rust-where-are-primitive-types-from.dj b/vhosts/blog/content/posts/2021-10-02/rust-where-are-primitive-types-from.dj
index 212cd3d6..9fa61d56 100644
--- a/vhosts/blog/content/posts/2021-10-02/rust-where-are-primitive-types-from.dj
+++ b/vhosts/blog/content/posts/2021-10-02/rust-where-are-primitive-types-from.dj
@@ -96,6 +96,7 @@ rustc_resolve/src/lib.rs: table.insert(sym::i128, Int(IntTy::I128));
`rustc_resolve`
というのはいかにも名前解決を担いそうなクレート名である。該当箇所を見てみる。
+{filename="rustc_resolve/src/lib.rs"}
```rust
/// Interns the names of the primitive types.
///
diff --git a/vhosts/blog/content/posts/2021-10-02/vim-difference-between-autocmd-bufwrite-and-bufwritepre.dj b/vhosts/blog/content/posts/2021-10-02/vim-difference-between-autocmd-bufwrite-and-bufwritepre.dj
index 37af679a..a97337d0 100644
--- a/vhosts/blog/content/posts/2021-10-02/vim-difference-between-autocmd-bufwrite-and-bufwritepre.dj
+++ b/vhosts/blog/content/posts/2021-10-02/vim-difference-between-autocmd-bufwrite-and-bufwritepre.dj
@@ -53,6 +53,7 @@ vim と neovim のソースコードを調査した。
https://github.com/vim/vim/blob/8e6be34338f13a6a625f19bcef82019c9adc65f2/src/autocmd.c#L85-L86
+{filename="src/autocmd.c"}
```c
{"BufAdd", EVENT_BUFADD},
{"BufCreate", EVENT_BUFADD},
@@ -60,6 +61,7 @@ https://github.com/vim/vim/blob/8e6be34338f13a6a625f19bcef82019c9adc65f2/src/aut
https://github.com/vim/vim/blob/8e6be34338f13a6a625f19bcef82019c9adc65f2/src/autocmd.c#L95-L97
+{filename="src/autocmd.c"}
```c
{"BufRead", EVENT_BUFREADPOST},
{"BufReadCmd", EVENT_BUFREADCMD},
@@ -68,6 +70,7 @@ https://github.com/vim/vim/blob/8e6be34338f13a6a625f19bcef82019c9adc65f2/src/aut
https://github.com/vim/vim/blob/8e6be34338f13a6a625f19bcef82019c9adc65f2/src/autocmd.c#L103-L105
+{filename="src/autocmd.c"}
```c
{"BufWrite", EVENT_BUFWRITEPRE},
{"BufWritePost", EVENT_BUFWRITEPOST},
@@ -82,6 +85,7 @@ neovim の場合でも同様のマッピングが定義されているが、こ
https://github.com/neovim/neovim/blob/71d4f5851f068eeb432af34850dddda8cc1c71e3/src/nvim/auevents.lua#L119-L124
+{filename="src/nvim/auevents.lua"}
```lua
aliases = {
BufCreate = 'BufAdd',
@@ -94,6 +98,7 @@ aliases = {
ところで、上では取り上げなかった `FileEncoding` だが、これは
`:help FileEncoding` にしっかりと書いてある。
+{filename=":help FileEncoding"}
```
*FileEncoding*
FileEncoding Obsolete. It still works and is equivalent