[PATCH 10/11] Add Python support for dynamic types

Matt Rice ratmice@gmail.com
Sat Apr 25 08:43:35 GMT 2020


On Fri, Apr 24, 2020 at 8:38 PM Tom Tromey <tom@tromey.com> wrote:
>
> >>>>> "Christian" == Christian Biesinger via Gdb-patches <gdb-patches@sourceware.org> writes:
>
> Christian> The "dynamic type" name is unfortunate, since it is unrelated to
> Christian> Value.dynamic_type AFAICT. I thought discriminated/tagged union was a
> Christian> more common name for this :(
>
> When I sent my earlier note, this hadn't fully sunk in I guess.  Maybe
> we ought to rename the "dynamic" type business.  It isn't too late, even
> though that's checked in.
>
> What do you think would be better?
>
> Tom

I know that Harper has used the terminology "Extensible", and the term
"Index", is commonly the generalization of Tag.
first paragraph from the paper by Licata & Harper, An Extensible
Theory of Indexed Types
http://www.cs.cmu.edu/~rwh/papers/extidx/paper.pdf

"Indexed families of types are a way of associating run-time data with
compile-time abstractions that can be used to reason about them. We
propose an extensible theory of indexed types, in which programmers
can define the index data appropriate to their programs and use them
to track properties of run-time code."

Extensible seems alright to me for the bool, in that the concrete data
obtained from the type is extensible beyond that what is statically
known about the type?

shrug


More information about the Gdb-patches mailing list