import { type validateTupleExpression } from "https://deno.land/x/arktype@v1.0.10-alpha/parse/ast/tuple.ts";
definition: def[1] extends "[]" ? conform<def, readonly [validateDefinition<def[0], $>, "[]"]> : def[1] extends Scanner.BranchToken ? def[2] extends undefined ? [def[0], error<writeMissingRightOperandMessage<def[1], "">>] : conform<def, readonly [validateDefinition<def[0], $>, def[1], validateDefinition<def[2], $>]> : def[1] extends "=>" ? validateNarrowTuple<def, $> : def[1] extends "|>" ? validateMorphTuple<def, $> : def[1] extends ":" ? validateConfigTuple<def, $> : def[0] extends "===" ? conform<def, readonly ["===", unknown]> : def[0] extends "instanceof" ? conform<def, readonly ["instanceof", constructor]> : def[0] extends "node" ? conform<def, readonly ["node", ResolvedNode<$>]> : def[0] extends "keyof" ? conform<def, validateKeyOfExpression<def[1], $>> : never