pdecvar.pas 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637
  1. {
  2. $Id$
  3. Copyright (c) 1998-2002 by Florian Klaempfl
  4. Parses variable declarations. Used for var statement and record
  5. definitions
  6. This program is free software; you can redistribute it and/or modify
  7. it under the terms of the GNU General Public License as published by
  8. the Free Software Foundation; either version 2 of the License, or
  9. (at your option) any later version.
  10. This program is distributed in the hope that it will be useful,
  11. but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. GNU General Public License for more details.
  14. You should have received a copy of the GNU General Public License
  15. along with this program; if not, write to the Free Software
  16. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  17. ****************************************************************************
  18. }
  19. unit pdecvar;
  20. {$i fpcdefs.inc}
  21. interface
  22. procedure read_var_decs(is_record,is_object,is_threadvar:boolean);
  23. implementation
  24. uses
  25. { common }
  26. cutils,
  27. { global }
  28. globtype,globals,tokens,verbose,
  29. systems,
  30. { symtable }
  31. symconst,symbase,symtype,symdef,symsym,symtable,defbase,fmodule,paramgr,
  32. { pass 1 }
  33. node,
  34. nmat,nadd,ncal,nset,ncnv,ninl,ncon,nld,nflw,
  35. { parser }
  36. scanner,
  37. pbase,pexpr,ptype,ptconst,pdecsub,
  38. { link }
  39. import;
  40. const
  41. variantrecordlevel : longint = 0;
  42. procedure read_var_decs(is_record,is_object,is_threadvar:boolean);
  43. { reads the filed of a record into a }
  44. { symtablestack, if record=false }
  45. { variants are forbidden, so this procedure }
  46. { can be used to read object fields }
  47. { if absolute is true, ABSOLUTE and file }
  48. { types are allowed }
  49. { => the procedure is also used to read }
  50. { a sequence of variable declaration }
  51. procedure insert_syms(st : tsymtable;sc : tidstringlist;tt : ttype;is_threadvar : boolean);
  52. { inserts the symbols of sc in st with def as definition or sym as ttypesym, sc is disposed }
  53. var
  54. s : string;
  55. filepos : tfileposinfo;
  56. ss,ss2 : tvarsym;
  57. begin
  58. filepos:=akttokenpos;
  59. while not sc.empty do
  60. begin
  61. s:=sc.get(akttokenpos);
  62. ss:=tvarsym.Create(s,tt);
  63. if is_threadvar then
  64. include(ss.varoptions,vo_is_thread_var);
  65. st.insert(ss);
  66. { static data fields are inserted in the globalsymtable }
  67. if (st.symtabletype=objectsymtable) and
  68. (sp_static in current_object_option) then
  69. begin
  70. ss2:=tvarsym.create('$'+lower(st.name^)+'_'+upper(s),tt);
  71. st.defowner.owner.insert(ss2);
  72. st.defowner.owner.insertvardata(ss2);
  73. end
  74. else
  75. begin
  76. { external data is not possible here }
  77. st.insertvardata(ss);
  78. end;
  79. end;
  80. {$ifdef fixLeaksOnError}
  81. if strContStack.pop <> sc then
  82. writeln('problem with strContStack in pdecl (2)');
  83. {$endif fixLeaksOnError}
  84. sc.free;
  85. akttokenpos:=filepos;
  86. end;
  87. var
  88. sc : tidstringList;
  89. s : stringid;
  90. old_block_type : tblock_type;
  91. declarepos,storetokenpos : tfileposinfo;
  92. oldsymtablestack : tsymtable;
  93. symdone : boolean;
  94. { to handle absolute }
  95. abssym : tabsolutesym;
  96. { c var }
  97. newtype : ttypesym;
  98. is_dll,
  99. is_gpc_name,is_cdecl,
  100. extern_aktvarsym,export_aktvarsym : boolean;
  101. old_current_object_option : tsymoptions;
  102. dll_name,
  103. C_name : string;
  104. tt,casetype : ttype;
  105. { Delphi initialized vars }
  106. tconstsym : ttypedconstsym;
  107. { maxsize contains the max. size of a variant }
  108. { startvarrec contains the start of the variant part of a record }
  109. usedalign,
  110. maxsize,minalignment,maxalignment,startvarrecalign,startvarrecsize : longint;
  111. pt : tnode;
  112. srsym : tsym;
  113. srsymtable : tsymtable;
  114. unionsymtable : tsymtable;
  115. offset : longint;
  116. uniondef : trecorddef;
  117. unionsym : tvarsym;
  118. uniontype : ttype;
  119. dummysymoptions : tsymoptions;
  120. begin
  121. old_current_object_option:=current_object_option;
  122. { all variables are public if not in a object declaration }
  123. if not is_object then
  124. current_object_option:=[sp_public];
  125. old_block_type:=block_type;
  126. block_type:=bt_type;
  127. is_gpc_name:=false;
  128. { Force an expected ID error message }
  129. if not (token in [_ID,_CASE,_END]) then
  130. consume(_ID);
  131. { read vars }
  132. while (token=_ID) and
  133. not(is_object and (idtoken in [_PUBLIC,_PRIVATE,_PUBLISHED,_PROTECTED])) do
  134. begin
  135. C_name:=orgpattern;
  136. sc:=consume_idlist;
  137. {$ifdef fixLeaksOnError}
  138. strContStack.push(sc);
  139. {$endif fixLeaksOnError}
  140. consume(_COLON);
  141. if (m_gpc in aktmodeswitches) and
  142. not(is_record or is_object or is_threadvar) and
  143. (token=_ID) and (orgpattern='__asmname__') then
  144. begin
  145. consume(_ID);
  146. C_name:=get_stringconst;
  147. Is_gpc_name:=true;
  148. end;
  149. { this is needed for Delphi mode at least
  150. but should be OK for all modes !! (PM) }
  151. ignore_equal:=true;
  152. if is_record then
  153. begin
  154. { for records, don't search the recordsymtable for
  155. the symbols of the types }
  156. oldsymtablestack:=symtablestack;
  157. symtablestack:=symtablestack.next;
  158. read_type(tt,'');
  159. symtablestack:=oldsymtablestack;
  160. end
  161. else
  162. read_type(tt,'');
  163. { types that use init/final are not allowed in variant parts, but
  164. classes are allowed }
  165. if (variantrecordlevel>0) and
  166. (tt.def.needs_inittable and not is_class(tt.def)) then
  167. Message(parser_e_cant_use_inittable_here);
  168. ignore_equal:=false;
  169. symdone:=false;
  170. if is_gpc_name then
  171. begin
  172. storetokenpos:=akttokenpos;
  173. s:=sc.get(akttokenpos);
  174. if not sc.empty then
  175. Message(parser_e_absolute_only_one_var);
  176. {$ifdef fixLeaksOnError}
  177. if strContStack.pop <> sc then
  178. writeln('problem with strContStack in pdecl (3)');
  179. {$endif fixLeaksOnError}
  180. sc.free;
  181. aktvarsym:=tvarsym.create_C(s,target_info.Cprefix+C_name,tt);
  182. include(aktvarsym.varoptions,vo_is_external);
  183. symtablestack.insert(aktvarsym);
  184. { external, so no insert in the data }
  185. akttokenpos:=storetokenpos;
  186. symdone:=true;
  187. end;
  188. { check for absolute }
  189. if not symdone and
  190. (idtoken=_ABSOLUTE) and not(is_record or is_object or is_threadvar) then
  191. begin
  192. consume(_ABSOLUTE);
  193. { only allowed for one var }
  194. s:=sc.get(declarepos);
  195. if not sc.empty then
  196. Message(parser_e_absolute_only_one_var);
  197. {$ifdef fixLeaksOnError}
  198. if strContStack.pop <> sc then
  199. writeln('problem with strContStack in pdecl (4)');
  200. {$endif fixLeaksOnError}
  201. sc.free;
  202. { parse the rest }
  203. pt:=expr;
  204. if (pt.nodetype=stringconstn) or (is_constcharnode(pt)) then
  205. begin
  206. storetokenpos:=akttokenpos;
  207. akttokenpos:=declarepos;
  208. abssym:=tabsolutesym.create(s,tt);
  209. if pt.nodetype=stringconstn then
  210. s:=strpas(tstringconstnode(pt).value_str)
  211. else
  212. s:=chr(tordconstnode(pt).value);
  213. consume(token);
  214. abssym.abstyp:=toasm;
  215. abssym.asmname:=stringdup(s);
  216. symtablestack.insert(abssym);
  217. akttokenpos:=storetokenpos;
  218. symdone:=true;
  219. end;
  220. if not symdone then
  221. begin
  222. { variable }
  223. if (pt.nodetype=loadn) then
  224. begin
  225. { we should check the result type of srsym }
  226. if not (tloadnode(pt).symtableentry.typ in [varsym,typedconstsym,funcretsym]) then
  227. Message(parser_e_absolute_only_to_var_or_const);
  228. storetokenpos:=akttokenpos;
  229. akttokenpos:=declarepos;
  230. abssym:=tabsolutesym.create(s,tt);
  231. abssym.abstyp:=tovar;
  232. abssym.ref:=tstoredsym(tloadnode(pt).symtableentry);
  233. symtablestack.insert(abssym);
  234. akttokenpos:=storetokenpos;
  235. symdone:=true;
  236. end
  237. { funcret }
  238. else if (pt.nodetype=funcretn) then
  239. begin
  240. storetokenpos:=akttokenpos;
  241. akttokenpos:=declarepos;
  242. abssym:=tabsolutesym.create(s,tt);
  243. abssym.abstyp:=tovar;
  244. abssym.ref:=tstoredsym(tfuncretnode(pt).funcretsym);
  245. symtablestack.insert(abssym);
  246. akttokenpos:=storetokenpos;
  247. symdone:=true;
  248. end;
  249. { address }
  250. if (not symdone) then
  251. begin
  252. if is_constintnode(pt) and
  253. ((target_info.system=system_i386_go32v2) or
  254. (m_objfpc in aktmodeswitches) or
  255. (m_delphi in aktmodeswitches)) then
  256. begin
  257. storetokenpos:=akttokenpos;
  258. akttokenpos:=declarepos;
  259. abssym:=tabsolutesym.create(s,tt);
  260. abssym.abstyp:=toaddr;
  261. abssym.absseg:=false;
  262. abssym.address:=tordconstnode(pt).value;
  263. if (token=_COLON) and
  264. (target_info.system=system_i386_go32v2) then
  265. begin
  266. consume(token);
  267. pt.free;
  268. pt:=expr;
  269. if is_constintnode(pt) then
  270. begin
  271. abssym.address:=abssym.address shl 4+tordconstnode(pt).value;
  272. abssym.absseg:=true;
  273. end
  274. else
  275. Message(parser_e_absolute_only_to_var_or_const);
  276. end;
  277. symtablestack.insert(abssym);
  278. akttokenpos:=storetokenpos;
  279. symdone := true;
  280. end
  281. else
  282. Message(parser_e_absolute_only_to_var_or_const);
  283. end
  284. end
  285. else
  286. Message(parser_e_absolute_only_to_var_or_const);
  287. if not symdone then
  288. begin
  289. tt := generrortype;
  290. symtablestack.insert(tvarsym.create(s,tt));
  291. symdone:=true;
  292. end;
  293. pt.free;
  294. end;
  295. { Handling of Delphi typed const = initialized vars ! }
  296. { When should this be rejected ?
  297. - in parasymtable
  298. - in record or object
  299. - ... (PM) }
  300. if (token=_EQUAL) and
  301. not(m_tp7 in aktmodeswitches) and
  302. not(symtablestack.symtabletype in [parasymtable]) and
  303. not is_record and
  304. not is_object then
  305. begin
  306. storetokenpos:=akttokenpos;
  307. s:=sc.get(akttokenpos);
  308. if not sc.empty then
  309. Message(parser_e_initialized_only_one_var);
  310. tconstsym:=ttypedconstsym.createtype(s,tt,true);
  311. symtablestack.insert(tconstsym);
  312. symtablestack.insertconstdata(tconstsym);
  313. akttokenpos:=storetokenpos;
  314. consume(_EQUAL);
  315. readtypedconst(tt,tconstsym,true);
  316. symdone:=true;
  317. end;
  318. { hint directive }
  319. {$warning hintdirective not stored in syms}
  320. dummysymoptions:=[];
  321. try_consume_hintdirective(dummysymoptions);
  322. { for a record there doesn't need to be a ; before the END or ) }
  323. if not((is_record or is_object) and (token in [_END,_RKLAMMER])) then
  324. consume(_SEMICOLON);
  325. { procvar handling }
  326. if (tt.def.deftype=procvardef) and (tt.def.typesym=nil) then
  327. begin
  328. newtype:=ttypesym.create('unnamed',tt);
  329. parse_var_proc_directives(tsym(newtype));
  330. paramanager.create_param_loc_info(tabstractprocdef(tt.def));
  331. newtype.restype.def:=nil;
  332. tt.def.typesym:=nil;
  333. newtype.free;
  334. end;
  335. { Check for variable directives }
  336. if not symdone and (token=_ID) then
  337. begin
  338. { Check for C Variable declarations }
  339. if (m_cvar_support in aktmodeswitches) and
  340. not(is_record or is_object or is_threadvar) and
  341. (idtoken in [_EXPORT,_EXTERNAL,_PUBLIC,_CVAR]) then
  342. begin
  343. { only allowed for one var }
  344. s:=sc.get(declarepos);
  345. if not sc.empty then
  346. Message(parser_e_absolute_only_one_var);
  347. {$ifdef fixLeaksOnError}
  348. if strContStack.pop <> sc then
  349. writeln('problem with strContStack in pdecl (5)');
  350. {$endif fixLeaksOnError}
  351. sc.free;
  352. { defaults }
  353. is_dll:=false;
  354. is_cdecl:=false;
  355. extern_aktvarsym:=false;
  356. export_aktvarsym:=false;
  357. { cdecl }
  358. if idtoken=_CVAR then
  359. begin
  360. consume(_CVAR);
  361. consume(_SEMICOLON);
  362. is_cdecl:=true;
  363. C_name:=target_info.Cprefix+C_name;
  364. end;
  365. { external }
  366. if idtoken=_EXTERNAL then
  367. begin
  368. consume(_EXTERNAL);
  369. extern_aktvarsym:=true;
  370. end;
  371. { export }
  372. if idtoken in [_EXPORT,_PUBLIC] then
  373. begin
  374. consume(_ID);
  375. if extern_aktvarsym or
  376. (symtablestack.symtabletype in [parasymtable,localsymtable]) then
  377. Message(parser_e_not_external_and_export)
  378. else
  379. export_aktvarsym:=true;
  380. end;
  381. { external and export need a name after when no cdecl is used }
  382. if not is_cdecl then
  383. begin
  384. { dll name ? }
  385. if (extern_aktvarsym) and (idtoken<>_NAME) then
  386. begin
  387. is_dll:=true;
  388. dll_name:=get_stringconst;
  389. end;
  390. consume(_NAME);
  391. C_name:=get_stringconst;
  392. end;
  393. { consume the ; when export or external is used }
  394. if extern_aktvarsym or export_aktvarsym then
  395. consume(_SEMICOLON);
  396. { insert in the symtable }
  397. storetokenpos:=akttokenpos;
  398. akttokenpos:=declarepos;
  399. if is_dll then
  400. aktvarsym:=tvarsym.create_dll(s,tt)
  401. else
  402. aktvarsym:=tvarsym.create_C(s,C_name,tt);
  403. { set some vars options }
  404. if export_aktvarsym then
  405. begin
  406. inc(aktvarsym.refs);
  407. include(aktvarsym.varoptions,vo_is_exported);
  408. end;
  409. if extern_aktvarsym then
  410. include(aktvarsym.varoptions,vo_is_external);
  411. { insert in the symtable }
  412. symtablestack.insert(aktvarsym);
  413. { insert in the datasegment when it is not external }
  414. if not extern_aktvarsym then
  415. symtablestack.insertvardata(aktvarsym);
  416. akttokenpos:=storetokenpos;
  417. { now we can insert it in the import lib if its a dll, or
  418. add it to the externals }
  419. if extern_aktvarsym then
  420. begin
  421. if is_dll then
  422. begin
  423. if not(current_module.uses_imports) then
  424. begin
  425. current_module.uses_imports:=true;
  426. importlib.preparelib(current_module.modulename^);
  427. end;
  428. importlib.importvariable(aktvarsym.mangledname,dll_name,C_name)
  429. end
  430. else
  431. if target_info.DllScanSupported then
  432. current_module.Externals.insert(tExternalsItem.create(aktvarsym.mangledname));
  433. end;
  434. symdone:=true;
  435. end
  436. else
  437. if (is_object) and (cs_static_keyword in aktmoduleswitches) and (idtoken=_STATIC) then
  438. begin
  439. include(current_object_option,sp_static);
  440. insert_syms(symtablestack,sc,tt,false);
  441. exclude(current_object_option,sp_static);
  442. consume(_STATIC);
  443. consume(_SEMICOLON);
  444. symdone:=true;
  445. end;
  446. end;
  447. { insert it in the symtable, if not done yet }
  448. if not symdone then
  449. begin
  450. { save object option, because we can turn of the sp_published }
  451. if (sp_published in current_object_option) and
  452. not(is_class(tt.def)) then
  453. begin
  454. Message(parser_e_cant_publish_that);
  455. exclude(current_object_option,sp_published);
  456. end
  457. else
  458. if (sp_published in current_object_option) and
  459. not(oo_can_have_published in tobjectdef(tt.def).objectoptions) then
  460. begin
  461. Message(parser_e_only_publishable_classes_can__be_published);
  462. exclude(current_object_option,sp_published);
  463. end;
  464. insert_syms(symtablestack,sc,tt,is_threadvar);
  465. current_object_option:=old_current_object_option;
  466. end;
  467. end;
  468. { Check for Case }
  469. if is_record and (token=_CASE) then
  470. begin
  471. maxsize:=0;
  472. maxalignment:=0;
  473. consume(_CASE);
  474. s:=pattern;
  475. searchsym(s,srsym,srsymtable);
  476. { may be only a type: }
  477. if assigned(srsym) and (srsym.typ in [typesym,unitsym]) then
  478. begin
  479. { for records, don't search the recordsymtable for
  480. the symbols of the types }
  481. oldsymtablestack:=symtablestack;
  482. symtablestack:=symtablestack.next;
  483. read_type(casetype,'');
  484. symtablestack:=oldsymtablestack;
  485. end
  486. else
  487. begin
  488. consume(_ID);
  489. consume(_COLON);
  490. { for records, don't search the recordsymtable for
  491. the symbols of the types }
  492. oldsymtablestack:=symtablestack;
  493. symtablestack:=symtablestack.next;
  494. read_type(casetype,'');
  495. symtablestack:=oldsymtablestack;
  496. aktvarsym:=tvarsym.create(s,casetype);
  497. symtablestack.insert(aktvarsym);
  498. symtablestack.insertvardata(aktvarsym);
  499. end;
  500. if not(is_ordinal(casetype.def)) or is_64bitint(casetype.def) then
  501. Message(type_e_ordinal_expr_expected);
  502. consume(_OF);
  503. UnionSymtable:=trecordsymtable.create;
  504. Unionsymtable.next:=symtablestack;
  505. registerdef:=false;
  506. UnionDef:=trecorddef.create(unionsymtable);
  507. registerdef:=true;
  508. symtablestack:=UnionSymtable;
  509. startvarrecsize:=symtablestack.datasize;
  510. startvarrecalign:=symtablestack.dataalignment;
  511. repeat
  512. repeat
  513. pt:=comp_expr(true);
  514. if not(pt.nodetype=ordconstn) then
  515. Message(cg_e_illegal_expression);
  516. pt.free;
  517. if token=_COMMA then
  518. consume(_COMMA)
  519. else
  520. break;
  521. until false;
  522. consume(_COLON);
  523. { read the vars }
  524. consume(_LKLAMMER);
  525. inc(variantrecordlevel);
  526. if token<>_RKLAMMER then
  527. read_var_decs(true,false,false);
  528. dec(variantrecordlevel);
  529. consume(_RKLAMMER);
  530. { calculates maximal variant size }
  531. maxsize:=max(maxsize,symtablestack.datasize);
  532. maxalignment:=max(maxalignment,symtablestack.dataalignment);
  533. { the items of the next variant are overlayed }
  534. symtablestack.datasize:=startvarrecsize;
  535. symtablestack.dataalignment:=startvarrecalign;
  536. if (token<>_END) and (token<>_RKLAMMER) then
  537. consume(_SEMICOLON)
  538. else
  539. break;
  540. until (token=_END) or (token=_RKLAMMER);
  541. { at last set the record size to that of the biggest variant }
  542. symtablestack.datasize:=maxsize;
  543. symtablestack.dataalignment:=maxalignment;
  544. uniontype.def:=uniondef;
  545. uniontype.sym:=nil;
  546. UnionSym:=tvarsym.create('case',uniontype);
  547. symtablestack:=symtablestack.next;
  548. { we do NOT call symtablestack.insert
  549. on purpose PM }
  550. if aktalignment.recordalignmax=-1 then
  551. begin
  552. {$ifdef i386}
  553. if maxalignment>2 then
  554. minalignment:=4
  555. else if maxalignment>1 then
  556. minalignment:=2
  557. else
  558. minalignment:=1;
  559. {$else}
  560. {$ifdef m68k}
  561. minalignment:=2;
  562. {$endif}
  563. minalignment:=1;
  564. {$endif}
  565. end
  566. else
  567. minalignment:=maxalignment;
  568. usedalign:=used_align(maxalignment,minalignment,maxalignment);
  569. offset:=align(symtablestack.datasize,usedalign);
  570. symtablestack.datasize:=offset+unionsymtable.datasize;
  571. if maxalignment>symtablestack.dataalignment then
  572. symtablestack.dataalignment:=maxalignment;
  573. trecordsymtable(Unionsymtable).Insert_in(symtablestack,offset);
  574. Unionsym.owner:=nil;
  575. unionsym.free;
  576. uniondef.free;
  577. end;
  578. block_type:=old_block_type;
  579. current_object_option:=old_current_object_option;
  580. end;
  581. end.
  582. {
  583. $Log$
  584. Revision 1.31 2002-08-25 19:25:20 peter
  585. * sym.insert_in_data removed
  586. * symtable.insertvardata/insertconstdata added
  587. * removed insert_in_data call from symtable.insert, it needs to be
  588. called separatly. This allows to deref the address calculation
  589. * procedures now calculate the parast addresses after the procedure
  590. directives are parsed. This fixes the cdecl parast problem
  591. * push_addr_param has an extra argument that specifies if cdecl is used
  592. or not
  593. Revision 1.30 2002/07/29 21:23:44 florian
  594. * more fixes for the ppc
  595. + wrappers for the tcnvnode.first_* stuff introduced
  596. Revision 1.29 2002/07/26 21:15:40 florian
  597. * rewrote the system handling
  598. Revision 1.28 2002/07/20 11:57:55 florian
  599. * types.pas renamed to defbase.pas because D6 contains a types
  600. unit so this would conflicts if D6 programms are compiled
  601. + Willamette/SSE2 instructions to assembler added
  602. Revision 1.27 2002/06/10 13:41:26 jonas
  603. * fixed bug 1985
  604. Revision 1.26 2002/05/18 13:34:12 peter
  605. * readded missing revisions
  606. Revision 1.25 2002/05/16 19:46:43 carl
  607. + defines.inc -> fpcdefs.inc to avoid conflicts if compiling by hand
  608. + try to fix temp allocation (still in ifdef)
  609. + generic constructor calls
  610. + start of tassembler / tmodulebase class cleanup
  611. Revision 1.23 2002/04/21 18:57:24 peter
  612. * fixed memleaks when file can't be opened
  613. }