Andrew Dunstan <[EMAIL PROTECTED]> writes: > Jeff Davis wrote: >> postgres=# create type mytype as int; >> CREATE DOMAIN
> Is that really the return message we want? That's an artifact of the fact that the patch tries to piggyback on the DOMAIN infrastructure instead of implementing its own statement type etc. The overly close relationship between domains and distinct types seems to also explain the fact that CREATE INDEX fails to fail. It looks like getBaseType() will happily smash a distinct type to its base, and Peter has put defenses to prevent that into some but not all call sites of getBaseType. I'm not sure why he did that rather than having the check inside getBaseType itself; if there's a principled explanation for having some of them behave differently, it sure isn't given in the patch. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers