1
0
mirror of https://github.com/postgres/postgres.git synced 2025-04-25 21:42:33 +03:00

Clarify description of typmod input function, per Jeff Davis.

This commit is contained in:
Tom Lane 2008-05-27 18:05:13 +00:00
parent ea7f9648fe
commit e35ee671a8

View File

@ -1,5 +1,5 @@
<!-- <!--
$PostgreSQL: pgsql/doc/src/sgml/ref/create_type.sgml,v 1.73 2007/10/29 17:29:59 momjian Exp $ $PostgreSQL: pgsql/doc/src/sgml/ref/create_type.sgml,v 1.74 2008/05/27 18:05:13 tgl Exp $
PostgreSQL documentation PostgreSQL documentation
--> -->
@ -196,7 +196,7 @@ CREATE TYPE <replaceable class="parameter">name</replaceable>
attached to a type declaration, such as <literal>char(5)</> or attached to a type declaration, such as <literal>char(5)</> or
<literal>numeric(30,2)</>. <productname>PostgreSQL</productname> allows <literal>numeric(30,2)</>. <productname>PostgreSQL</productname> allows
user-defined types to take one or more simple constants or identifiers as user-defined types to take one or more simple constants or identifiers as
modifiers; however, this information must be capable of being packed into a modifiers. However, this information must be capable of being packed into a
single non-negative integer value for storage in the system catalogs. The single non-negative integer value for storage in the system catalogs. The
<replaceable class="parameter">type_modifier_input_function</replaceable> <replaceable class="parameter">type_modifier_input_function</replaceable>
is passed the declared modifier(s) in the form of a <type>cstring</> is passed the declared modifier(s) in the form of a <type>cstring</>
@ -212,8 +212,8 @@ CREATE TYPE <replaceable class="parameter">name</replaceable>
function might return <literal>(30,2)</>. function might return <literal>(30,2)</>.
It is allowed to omit the It is allowed to omit the
<replaceable class="parameter">type_modifier_output_function</replaceable>, <replaceable class="parameter">type_modifier_output_function</replaceable>,
in which case the default display format is just the stored typmod value in which case the default display format is just the stored typmod integer
enclosed in parentheses. value enclosed in parentheses.
</para> </para>
<para> <para>
@ -433,7 +433,7 @@ CREATE TYPE <replaceable class="parameter">name</replaceable>
<term><replaceable class="parameter">type_modifier_input_function</replaceable></term> <term><replaceable class="parameter">type_modifier_input_function</replaceable></term>
<listitem> <listitem>
<para> <para>
The name of a function that converts numeric modifier(s) for the type The name of a function that converts an array of modifier(s) for the type
into internal form. into internal form.
</para> </para>
</listitem> </listitem>