import { AnyExecutor } from '../internal/match-execution' ; import { isMatched , trackUnmatched } from '../internal/match-tracking' ; import { Matched , Unmatched } from '../internal/match-tracking/types' ; import { ExhaustiveStrikeSigs , NonExhaustiveStrikeSigs , } from '../internal/overloads/strike' ; description Use this function when you have a value
 * and you want to test it against a pattern.
 *
 *  strike will iterate through your
 * Matchers and use the first match's
 * Transformer to map `val` to a `TOut`.
 *
 * strike is comparable to the `match`
 * operator in Rust, F#, and other languages
 * with idiomatic Pattern Matching.
 *
 *  see pattern since example export const strike = < TIn , TOut > ( val , ... matchers ) : TIn | TOut => { let tracker = trackUnmatched ( val ) ; for ( const matcher of matchers ) { tracker = matcher ( tracker ) ; if ( isMatched ( tracker ) ) break ; } return tracker . val ; } ;