标签联合(英语:tagged union)也称可辨识联合(discriminated union)或者变体类型(variant type),指的是这样的一种数据结构,它能够存储一组不同但是固定的类型中某个类型的对象,具体是哪个类型由标签字段决定。这种数据结构在解释器、数据库和数据通信中非常有用。需要注意的是,可辨识联合英文原词在数学中又指不相交并集disjoint union)。

外部链接

Wikiwand in your browser!

Seamless Wikipedia browsing. On steroids.

Every time you click a link to Wikipedia, Wiktionary or Wikiquote in your browser's search results, it will show the modern Wikiwand interface.

Wikiwand extension is a five stars, simple, with minimum permission required to keep your browsing private, safe and transparent.