File tree Expand file tree Collapse file tree 3 files changed +19
-2
lines changed
Units/parser-sql.r/types.d Expand file tree Collapse file tree 3 files changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -22,3 +22,8 @@ obj input.sql /^ obj bigobj$/;" E table:big_objs roles:def
2222casttesttype input.sql /^CREATE TYPE casttesttype;$/;" k roles:decl
2323casttesttype_in input.sql /^CREATE FUNCTION casttesttype_in(cstring)$/;" f typeref:typename:casttesttype roles:def
2424textin input.sql /^ AS 'textin'$/;" f roles:foreigncall
25+ tststats input-0.sql /^CREATE schema tststats;$/;" S roles:def
26+ ty input-0.sql /^CREATE TYPE tststats.ty AS (a int, b int, c text);$/;" k roles:def
27+ a input-0.sql /^CREATE TYPE tststats.ty AS (a int, b int, c text);$/;" E type:ty roles:def
28+ b input-0.sql /^CREATE TYPE tststats.ty AS (a int, b int, c text);$/;" E type:ty roles:def
29+ c input-0.sql /^CREATE TYPE tststats.ty AS (a int, b int, c text);$/;" E type:ty roles:def
Original file line number Diff line number Diff line change 1+ -- Taken from postgresql/src/test/regress/sql/stats_ext.sql
2+ CREATE schema tststats ;
3+ CREATE TYPE tststats .ty AS (a int , b int , c text );
Original file line number Diff line number Diff line change @@ -1732,13 +1732,22 @@ static void parseType (tokenInfo *const token)
17321732 /* If a scope has been set, add it to the name */
17331733 addToScope (name , token -> scope , token -> scopeKind );
17341734 saveScopeKind = token -> scopeKind ;
1735- readToken (name );
1735+ readIdentifier (name );
1736+
1737+ while (isType (name , TOKEN_IDENTIFIER ))
1738+ {
1739+ readToken (token );
1740+ if (!isType (token , TOKEN_PERIOD ))
1741+ break ;
1742+ /* FIXME: Throw away valuable scope information. */
1743+ readIdentifier (name );
1744+ }
1745+
17361746 if (isType (name , TOKEN_IDENTIFIER ))
17371747 {
17381748 int r = makeSqlTag (name , SQLTAG_TYPE );
17391749 sqlKind scopeKind = SQLTAG_TYPE ;
17401750
1741- readToken (token );
17421751 if (isKeyword (token , KEYWORD_is ))
17431752 {
17441753 readToken (token );
You can’t perform that action at this time.
0 commit comments