UniqueNames

org.sigilaris.core.application.support.compiletime.UniqueNames
See theUniqueNames companion trait
object UniqueNames

Companion for UniqueNames, providing derivation instances for empty, single, and cons cases.

Attributes

Companion
trait
Source
Evidence.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Givens

Givens

given consUnique[Name <: String, K, V, Tail <: Tuple](using tailUnique: UniqueNames[Tail], notInTail: NameNotInSchema[Name, Tail]): UniqueNames[Entry[Name, K, V] *: Tail]

Inductive case: if head name is not in tail and tail is unique, then head *: tail is unique.

Inductive case: if head name is not in tail and tail is unique, then head *: tail is unique.

This implementation requires:

  1. The tail has unique names (recursive) 2. The head name does not appear in the tail (NameNotInSchema)

Attributes

Source
Evidence.scala
given emptyUnique: UniqueNames[EmptyTuple]

EmptyTuple trivially has unique names.

EmptyTuple trivially has unique names.

Attributes

Source
Evidence.scala
given singleUnique[Name <: String, K, V]: UniqueNames[EntryTuple[Name, K, V]]

Single entry trivially has unique names.

Single entry trivially has unique names.

Attributes

Source
Evidence.scala