Combining struct literal syntax with read-only field access

Recently, I found myself struggling with a small annoyance related to struct field visibility and struct initialization in Rust. It’s no rocket science, but I thought about it long enough that I might as well turn it into a blog post.

添加评论
点赞收藏
点踩分享查看原文
评论
?
参与讨论