git-svn-id: trunk@31507 -
@@ -524,6 +524,7 @@ compiler/pdecsub.pas svneol=native#text/plain
compiler/pdecvar.pas svneol=native#text/plain
compiler/pexports.pas svneol=native#text/plain
compiler/pexpr.pas svneol=native#text/plain
+compiler/pgentype.pas svneol=native#text/pascal
compiler/pgenutil.pas svneol=native#text/pascal
compiler/pinline.pas svneol=native#text/plain
compiler/pmodules.pas svneol=native#text/plain
@@ -0,0 +1,43 @@
+{
+ Copyright (c) 2015 by Sven Barth
+
+ Contains different types that are used in the context of parsing generics.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ ****************************************************************************
+}
+unit pgentype;
+{$i fpcdefs.inc}
+interface
+uses
+ cclasses,
+ symbase;
+type
+ tspecializationstate = record
+ oldsymtablestack : tsymtablestack;
+ oldextendeddefs : tfphashobjectlist;
+ oldgenericdummysyms: tfphashobjectlist;
+ end;
+implementation
+end.
@@ -31,6 +31,8 @@ uses
cclasses,
{ global }
globtype,
+ { parser }
+ pgentype,
{ symtable }
symtype,symdef,symbase;
@@ -45,13 +47,6 @@ uses
function resolve_generic_dummysym(const name:tidstring):tsym;
function could_be_generic(const name:tidstring):boolean;inline;
- type
- tspecializationstate = record
- oldsymtablestack : tsymtablestack;
- oldextendeddefs : TFPHashObjectList;
- oldgenericdummysyms: tfphashobjectlist;
- end;
-
procedure specialization_init(genericdef:tdef;var state:tspecializationstate);
procedure specialization_done(var state:tspecializationstate);
@@ -113,7 +113,7 @@ implementation
{$endif}
{ parser }
scanner,gendef,
- pbase,pstatmnt,pdecl,pdecsub,pexports,pgenutil,pparautl,
+ pbase,pstatmnt,pdecl,pdecsub,pexports,pgenutil,pparautl,pgentype,
{ codegen }
tgobj,cgbase,cgobj,cgutils,hlcgobj,hlcgcpu,dbgbase,
{$ifdef llvm}