[Python-ideas] An ABC representing "Iterable, Sized, Container"

Ryan Gonzalez rymg19 at gmail.com
Mon Jul 25 20:22:23 EDT 2016


I can't recall which, but I remember reading about a language with a
relative complement operator on types. The idea is, where T is a set of
types, then:

T \ {A, B, ...}

would be all types in T *except* A, B, ....

I think maybe there could be a type variable Except that could be used like:

Except[T, A, B, ...]

where T is a type variable. (Other name ideas: Complement, Difference).

--
Ryan
[ERROR]: Your autotools build scripts are 200 lines longer than your
program. Something’s wrong.
http://kirbyfan64.github.io/
On Jul 25, 2016 6:58 PM, "Greg Ewing" <greg.ewing at canterbury.ac.nz> wrote:

> Bar Harel wrote:
>
>> Soon enough we'll have NotBytesSequence, NumericSequenceWithoutFloat and
>> BuiltinNotCustomMadeIterable.
>>
>
> Is there some way we could provide a general way of
> constructing a "but not" ABC, so that people could
> build their own combinations as needed?
>
> --
> Greg
>
> _______________________________________________
> Python-ideas mailing list
> Python-ideas at python.org
> https://mail.python.org/mailman/listinfo/python-ideas
> Code of Conduct: http://python.org/psf/codeofconduct/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20160725/93b717a6/attachment.html>


More information about the Python-ideas mailing list