← 返回刚才阅读的位置

知识卡片

普通读书笔记卡 · 4545.g.8

静态类型提前暴露不匹配

理解等级:中级

类型约束让编译器在执行前发现一部分值与操作不匹配,签名也向维护者说明参数含义。原书以变量拼写和参数不明比较维护成本;静态类型并不证明业务逻辑正确,也不能单凭类型制度推导统一性能排序。历史基准只反映当时的选定实现与任务。

这张卡片看不懂?

已有反馈 · 0 条

    还没有人提交反馈。

    在整书笔记中的位置

    原书出处 · 1 处

    • Why Go Rules the Cloud Native World · 查看原书依据

      Explicitly defined types can guide development and ease the mental burden of writing code by automatically tracking information the programmer would otherwise have to track mentally by serving as documentation for both the programmer and everybody who has to maintain her code. Summary If Chapter 1 focused on what makes a system “cloud native”, then

    参考来源

    - 位置:《Cloud Native Go》第02章《Why Go Rules the Cloud Native World》(来源项目book-sources;源文件:extracted/Cloud Native Go (Matthew A. Titmus)/_epub-src/OEBPS/ch02.xhtml) - 结论依据:类型约束让编译器在执行前发现一部分值与操作不匹配,签名也向维护者说明参数含义。原文相应定义、示例或限制为此结论提供依据;补充纠错与版本边界在正文就近标明。 - 原始内容:Explicitly defined types can guide development and ease the mental burden of writing code by automatically tracking information the programmer would otherwise have to track mentally by serving as documentation for both the programmer and everybody who has to maintain her code. Summary If Chapter 1 focused on what makes a system “cloud native”, then