Avatar
Kishikawa Katsumi 12/8/2022 1:47 PM
マクロでコマンドプラグインと同等のパーミッションみたいな仕組みでファイルにアクセスしたい、っていうのを聞いてみたよ。 https://forums.swift.org/t/pitch-2-expression-macros/61861/9 (edited)
I am considering using macros to embed binaries into Swift source code. EXAMPLE: let data = #embed("images/icon.png") // ^ This macro will generate the code below. let data = Data([0x4d, 0x49, 0x54, ..., 0x65, 0x6e, 0x73]) Similar to the #embed macro in C23. This would be useful for applications that do not have bundles, such as command-lin...
👀 1