Todos os livros

Profissional

Apps Sobre Coach Entrar Começar a ler

Computer Science · Glossário

O que é Newtype?

Definition 8.11 University Computer Science — Year 2 · Capítulo 8 — Traits and Generics

A newtype is a struct with a single field, struct Metres(f64);, that gives an existing type a new name and a new set of operations: those implemented for it, and no others.

Ler no capítulo →