Esempio n. 1
0
            public List <Tuple <int, int> > Call <Name>(Named <List <int>, Name> named)
            {
                var len1 = Zipper.Len(this.xs);
                var len2 = Zipper.Len(named);

                var proof1 = Zipper.LengthIsTwo(len1);
                var proof2 = Zipper.LengthIsTwo(len2);

                if (proof1 != null && proof2 != null)
                {
                    return(Zipper.Zip(
                               new SuchThat <Named <List <int>, Xs>, Equals <Length <Xs>, Succ <Succ <Zero> > > >(this.xs, proof1),
                               new SuchThat <Named <List <int>, Name>, Equals <Length <Name>, Succ <Succ <Zero> > > >(named, proof2)));
                }
                throw new Exception("Lists were not of length 2.");
            }