PLDB
Languages Features Calendar About Lists Add Language
GitHub icon

Refinement Types

Refinement Types

Refinement Types are a language feature.

A type endowed with a predicate which is assumed to hold for any element of the refined type.

Languages with Refinement Types include Raku

Example from Raku:

subset Color of Any where Color | CMYK_Color;

Article source

PLDB - Build the next great programming language 路 v2022 Docs Editor Acknowledgements Email GitHub