全部书籍

专业

应用 关于 Coach 登录 开始阅读

书籍暂未推出简体中文版——当前显示英文版。

Computer Science · 术语表

什么是 Option type?

Definition 7.6 University Computer Science — Year 2 · 第 7 章 — Enums, Pattern Matching and Error Handling

The option type Option<T> of the standard library is the enum with the variants Some(T) and None. It is the type of a value that may be absent, and replaces the null pointer and the reserved no value code.

在原文中阅读 →