ptype.pas 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772
  1. {
  2. $Id$
  3. Copyright (c) 1998-2000 by Florian Klaempfl
  4. Does parsing types for Free Pascal
  5. This program is free software; you can redistribute it and/or modify
  6. it under the terms of the GNU General Public License as published by
  7. the Free Software Foundation; either version 2 of the License, or
  8. (at your option) any later version.
  9. This program is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. GNU General Public License for more details.
  13. You should have received a copy of the GNU General Public License
  14. along with this program; if not, write to the Free Software
  15. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  16. ****************************************************************************
  17. }
  18. unit ptype;
  19. {$i defines.inc}
  20. interface
  21. uses
  22. globtype,symtype;
  23. const
  24. { forward types should only be possible inside a TYPE statement }
  25. typecanbeforward : boolean = false;
  26. var
  27. { hack, which allows to use the current parsed }
  28. { object type as function argument type }
  29. testcurobject : byte;
  30. curobjectname : stringid;
  31. { reads a string, file type or a type id and returns a name and }
  32. { tdef }
  33. procedure single_type(var tt:ttype;var s : string;isforwarddef:boolean);
  34. procedure read_type(var tt:ttype;const name : stringid);
  35. { reads a type definition }
  36. { to a appropriating tdef, s gets the name of }
  37. { the type to allow name mangling }
  38. procedure id_type(var tt : ttype;var s : string;isforwarddef:boolean);
  39. implementation
  40. uses
  41. { common }
  42. cutils,cpuinfo,
  43. { global }
  44. globals,tokens,verbose,
  45. systems,
  46. { symtable }
  47. symconst,symbase,symdef,symsym,symtable,types,
  48. { pass 1 }
  49. node,
  50. nmat,nadd,ncal,nset,ncnv,ninl,ncon,nld,nflw,
  51. { parser }
  52. scanner,
  53. pbase,pexpr,pdecsub,pdecvar,pdecobj;
  54. procedure id_type(var tt : ttype;var s : string;isforwarddef:boolean);
  55. { reads a type definition }
  56. { to a appropriating tdef, s gets the name of }
  57. { the type to allow name mangling }
  58. var
  59. is_unit_specific : boolean;
  60. pos : tfileposinfo;
  61. srsym : tsym;
  62. srsymtable : tsymtable;
  63. sorg : stringid;
  64. begin
  65. s:=pattern;
  66. sorg:=orgpattern;
  67. pos:=akttokenpos;
  68. { classes can be used also in classes }
  69. if (curobjectname=pattern) and is_class_or_interface(aktobjectdef) then
  70. begin
  71. tt.setdef(aktobjectdef);
  72. consume(_ID);
  73. exit;
  74. end;
  75. { objects can be parameters }
  76. if (testcurobject=2) and (curobjectname=pattern) then
  77. begin
  78. tt.setdef(aktobjectdef);
  79. consume(_ID);
  80. exit;
  81. end;
  82. { try to load the symbol to see if it's a unitsym }
  83. is_unit_specific:=false;
  84. searchsym(s,srsym,srsymtable);
  85. consume(_ID);
  86. if assigned(srsym) and
  87. (srsym.typ=unitsym) then
  88. begin
  89. is_unit_specific:=true;
  90. consume(_POINT);
  91. if srsym.owner.unitid=0 then
  92. begin
  93. srsym:=searchsymonlyin(tunitsym(srsym).unitsymtable,pattern);
  94. pos:=akttokenpos;
  95. s:=pattern;
  96. end
  97. else
  98. srsym:=nil;
  99. consume(_ID);
  100. end;
  101. { are we parsing a possible forward def ? }
  102. if isforwarddef and
  103. not(is_unit_specific) then
  104. begin
  105. tt.setdef(tforwarddef.create(s,pos));
  106. exit;
  107. end;
  108. { unknown sym ? }
  109. if not assigned(srsym) then
  110. begin
  111. Message1(sym_e_id_not_found,sorg);
  112. tt:=generrortype;
  113. exit;
  114. end;
  115. { type sym ? }
  116. if (srsym.typ<>typesym) then
  117. begin
  118. Message(type_e_type_id_expected);
  119. tt:=generrortype;
  120. exit;
  121. end;
  122. { Types are first defined with an error def before assigning
  123. the real type so check if it's an errordef. if so then
  124. give an error }
  125. if (ttypesym(srsym).restype.def.deftype=errordef) then
  126. begin
  127. Message(sym_e_error_in_type_def);
  128. tt:=generrortype;
  129. exit;
  130. end;
  131. { Only use the definitions for system/current unit, becuase
  132. they can be refered from the parameters and symbols are not
  133. loaded at that time. A symbol reference to an other unit
  134. is still possible, because it's already loaded (PFV)
  135. can't use in [] here, becuase unitid can be > 255 }
  136. if (ttypesym(srsym).owner.unitid=0) or
  137. (ttypesym(srsym).owner.unitid=1) then
  138. tt.setdef(ttypesym(srsym).restype.def)
  139. else
  140. tt.setsym(srsym);
  141. end;
  142. procedure single_type(var tt:ttype;var s : string;isforwarddef:boolean);
  143. { reads a string, file type or a type id and returns a name and }
  144. { tdef }
  145. var
  146. hs : string;
  147. t2 : ttype;
  148. begin
  149. case token of
  150. _STRING:
  151. begin
  152. string_dec(tt);
  153. s:='STRING';
  154. end;
  155. _FILE:
  156. begin
  157. consume(_FILE);
  158. if token=_OF then
  159. begin
  160. consume(_OF);
  161. single_type(t2,hs,false);
  162. tt.setdef(tfiledef.createtyped(t2));
  163. s:='FILE$OF$'+hs;
  164. end
  165. else
  166. begin
  167. tt:=cfiletype;
  168. s:='FILE';
  169. end;
  170. end;
  171. _ID:
  172. begin
  173. id_type(tt,s,isforwarddef);
  174. end;
  175. else
  176. begin
  177. message(type_e_type_id_expected);
  178. s:='<unknown>';
  179. tt:=generrortype;
  180. end;
  181. end;
  182. end;
  183. { reads a record declaration }
  184. function record_dec : tdef;
  185. var
  186. symtable : tsymtable;
  187. storetypecanbeforward : boolean;
  188. old_object_option : tsymoptions;
  189. begin
  190. { create recdef }
  191. symtable:=trecordsymtable.create;
  192. record_dec:=trecorddef.create(symtable);
  193. { update symtable stack }
  194. symtable.next:=symtablestack;
  195. symtablestack:=symtable;
  196. { parse record }
  197. consume(_RECORD);
  198. old_object_option:=current_object_option;
  199. current_object_option:=[sp_public];
  200. storetypecanbeforward:=typecanbeforward;
  201. { for tp7 don't allow forward types }
  202. if m_tp7 in aktmodeswitches then
  203. typecanbeforward:=false;
  204. read_var_decs(true,false,false);
  205. consume(_END);
  206. typecanbeforward:=storetypecanbeforward;
  207. current_object_option:=old_object_option;
  208. { may be scale record size to a size of n*4 ? }
  209. symtablestack.datasize:=align(symtablestack.datasize,symtablestack.dataalignment);
  210. { restore symtable stack }
  211. symtablestack:=symtable.next;
  212. end;
  213. { reads a type definition and returns a pointer to it }
  214. procedure read_type(var tt : ttype;const name : stringid);
  215. var
  216. pt : tnode;
  217. tt2 : ttype;
  218. aktenumdef : tenumdef;
  219. ap : tarraydef;
  220. s : stringid;
  221. l,v : TConstExprInt;
  222. oldaktpackrecords : longint;
  223. hs : string;
  224. defpos,storepos : tfileposinfo;
  225. procedure expr_type;
  226. var
  227. pt1,pt2 : tnode;
  228. lv,hv : TConstExprInt;
  229. begin
  230. { use of current parsed object ? }
  231. if (token=_ID) and (testcurobject=2) and (curobjectname=pattern) then
  232. begin
  233. consume(_ID);
  234. tt.setdef(aktobjectdef);
  235. exit;
  236. end;
  237. { classes can be used also in classes }
  238. if (curobjectname=pattern) and is_class_or_interface(aktobjectdef) then
  239. begin
  240. tt.setdef(aktobjectdef);
  241. consume(_ID);
  242. exit;
  243. end;
  244. { we can't accept a equal in type }
  245. pt1:=comp_expr(not(ignore_equal));
  246. if (token=_POINTPOINT) then
  247. begin
  248. consume(_POINTPOINT);
  249. { get high value of range }
  250. pt2:=comp_expr(not(ignore_equal));
  251. { make both the same type }
  252. inserttypeconv(pt1,pt2.resulttype);
  253. { both must be evaluated to constants now }
  254. if (pt1.nodetype=ordconstn) and
  255. (pt2.nodetype=ordconstn) then
  256. begin
  257. lv:=tordconstnode(pt1).value;
  258. hv:=tordconstnode(pt2).value;
  259. { Check bounds }
  260. if hv<lv then
  261. Message(cg_e_upper_lower_than_lower)
  262. else
  263. begin
  264. { All checks passed, create the new def }
  265. case pt1.resulttype.def.deftype of
  266. enumdef :
  267. tt.setdef(tenumdef.create_subrange(tenumdef(pt1.resulttype.def),lv,hv));
  268. orddef :
  269. begin
  270. if is_char(pt1.resulttype.def) then
  271. tt.setdef(torddef.create(uchar,lv,hv))
  272. else
  273. if is_boolean(pt1.resulttype.def) then
  274. tt.setdef(torddef.create(bool8bit,l,hv))
  275. else
  276. tt.setdef(torddef.create(range_to_basetype(lv,hv),lv,hv));
  277. end;
  278. end;
  279. end;
  280. end
  281. else
  282. Message(sym_e_error_in_type_def);
  283. pt2.free;
  284. end
  285. else
  286. begin
  287. { a simple type renaming }
  288. if (pt1.nodetype=typen) then
  289. tt:=ttypenode(pt1).resulttype
  290. else
  291. Message(sym_e_error_in_type_def);
  292. end;
  293. pt1.free;
  294. end;
  295. procedure array_dec;
  296. var
  297. lowval,
  298. highval : longint;
  299. arraytype : ttype;
  300. ht : ttype;
  301. procedure setdefdecl(const t:ttype);
  302. begin
  303. case t.def.deftype of
  304. enumdef :
  305. begin
  306. lowval:=tenumdef(t.def).min;
  307. highval:=tenumdef(t.def).max;
  308. if tenumdef(t.def).has_jumps then
  309. Message(type_e_array_index_enums_with_assign_not_possible);
  310. arraytype:=t;
  311. end;
  312. orddef :
  313. begin
  314. if torddef(t.def).typ in [uchar,
  315. u8bit,u16bit,
  316. s8bit,s16bit,s32bit,
  317. bool8bit,bool16bit,bool32bit,
  318. uwidechar] then
  319. begin
  320. lowval:=torddef(t.def).low;
  321. highval:=torddef(t.def).high;
  322. arraytype:=t;
  323. end
  324. else
  325. Message1(parser_e_type_cant_be_used_in_array_index,t.def.gettypename);
  326. end;
  327. else
  328. Message(sym_e_error_in_type_def);
  329. end;
  330. end;
  331. begin
  332. consume(_ARRAY);
  333. { open array? }
  334. if token=_LECKKLAMMER then
  335. begin
  336. consume(_LECKKLAMMER);
  337. { defaults }
  338. arraytype:=generrortype;
  339. lowval:=longint($80000000);
  340. highval:=$7fffffff;
  341. tt.reset;
  342. repeat
  343. { read the expression and check it, check apart if the
  344. declaration is an enum declaration because that needs to
  345. be parsed by readtype (PFV) }
  346. if token=_LKLAMMER then
  347. begin
  348. read_type(ht,'');
  349. setdefdecl(ht);
  350. end
  351. else
  352. begin
  353. pt:=expr;
  354. if pt.nodetype=typen then
  355. setdefdecl(pt.resulttype)
  356. else
  357. begin
  358. if (pt.nodetype=rangen) then
  359. begin
  360. if (trangenode(pt).left.nodetype=ordconstn) and
  361. (trangenode(pt).right.nodetype=ordconstn) then
  362. begin
  363. lowval:=tordconstnode(trangenode(pt).left).value;
  364. highval:=tordconstnode(trangenode(pt).right).value;
  365. if highval<lowval then
  366. begin
  367. Message(parser_e_array_lower_less_than_upper_bound);
  368. highval:=lowval;
  369. end;
  370. arraytype:=trangenode(pt).right.resulttype;
  371. end
  372. else
  373. Message(type_e_cant_eval_constant_expr);
  374. end
  375. else
  376. Message(sym_e_error_in_type_def)
  377. end;
  378. pt.free;
  379. end;
  380. { create arraydef }
  381. if not assigned(tt.def) then
  382. begin
  383. ap:=tarraydef.create(lowval,highval,arraytype);
  384. tt.setdef(ap);
  385. end
  386. else
  387. begin
  388. ap.elementtype.setdef(tarraydef.create(lowval,highval,arraytype));
  389. ap:=tarraydef(ap.elementtype.def);
  390. end;
  391. if token=_COMMA then
  392. consume(_COMMA)
  393. else
  394. break;
  395. until false;
  396. consume(_RECKKLAMMER);
  397. end
  398. else
  399. begin
  400. ap:=tarraydef.create(0,-1,s32bittype);
  401. ap.IsDynamicArray:=true;
  402. tt.setdef(ap);
  403. end;
  404. consume(_OF);
  405. read_type(tt2,'');
  406. { if no error, set element type }
  407. if assigned(ap) then
  408. ap.elementtype:=tt2;
  409. end;
  410. var
  411. p : tnode;
  412. enumdupmsg : boolean;
  413. begin
  414. tt.reset;
  415. case token of
  416. _STRING,_FILE:
  417. begin
  418. single_type(tt,hs,false);
  419. end;
  420. _LKLAMMER:
  421. begin
  422. consume(_LKLAMMER);
  423. { allow negativ value_str }
  424. l:=-1;
  425. enumdupmsg:=false;
  426. aktenumdef:=tenumdef.create;
  427. repeat
  428. s:=orgpattern;
  429. defpos:=akttokenpos;
  430. consume(_ID);
  431. { only allow assigning of specific numbers under fpc mode }
  432. if (m_fpc in aktmodeswitches) and
  433. (token=_ASSIGNMENT) then
  434. begin
  435. consume(_ASSIGNMENT);
  436. p:=comp_expr(true);
  437. if (p.nodetype=ordconstn) then
  438. begin
  439. { we expect an integer or an enum of the
  440. same type }
  441. if is_integer(p.resulttype.def) or
  442. is_char(p.resulttype.def) or
  443. is_equal(p.resulttype.def,aktenumdef) then
  444. v:=tordconstnode(p).value
  445. else
  446. Message2(type_e_incompatible_types,p.resulttype.def.typename,s32bittype.def.typename);
  447. end
  448. else
  449. Message(cg_e_illegal_expression);
  450. p.free;
  451. { please leave that a note, allows type save }
  452. { declarations in the win32 units ! }
  453. if (v<=l) and (not enumdupmsg) then
  454. begin
  455. Message(parser_n_duplicate_enum);
  456. enumdupmsg:=true;
  457. end;
  458. l:=v;
  459. end
  460. else if (m_delphi in aktmodeswitches) and
  461. (token=_EQUAL) then
  462. begin
  463. consume(_EQUAL);
  464. p:=comp_expr(true);
  465. if (p.nodetype=ordconstn) then
  466. begin
  467. { we expect an integer or an enum of the
  468. same type }
  469. if is_integer(p.resulttype.def) or
  470. is_equal(p.resulttype.def,aktenumdef) then
  471. l:=tordconstnode(p).value
  472. else
  473. Message2(type_e_incompatible_types,p.resulttype.def.typename,s32bittype.def.typename);
  474. end
  475. else
  476. Message(cg_e_illegal_expression);
  477. p.free;
  478. end
  479. else
  480. inc(l);
  481. storepos:=akttokenpos;
  482. akttokenpos:=defpos;
  483. constsymtable.insert(tenumsym.create(s,aktenumdef,l));
  484. akttokenpos:=storepos;
  485. until not try_to_consume(_COMMA);
  486. tt.setdef(aktenumdef);
  487. consume(_RKLAMMER);
  488. end;
  489. _ARRAY:
  490. begin
  491. array_dec;
  492. end;
  493. _SET:
  494. begin
  495. consume(_SET);
  496. consume(_OF);
  497. read_type(tt2,'');
  498. if assigned(tt2.def) then
  499. begin
  500. case tt2.def.deftype of
  501. { don't forget that min can be negativ PM }
  502. enumdef :
  503. if tenumdef(tt2.def).min>=0 then
  504. tt.setdef(tsetdef.create(tt2,tenumdef(tt2.def).max))
  505. else
  506. Message(sym_e_ill_type_decl_set);
  507. orddef :
  508. begin
  509. case torddef(tt2.def).typ of
  510. uchar :
  511. tt.setdef(tsetdef.create(tt2,255));
  512. u8bit,u16bit,u32bit,
  513. s8bit,s16bit,s32bit :
  514. begin
  515. if (torddef(tt2.def).low>=0) then
  516. tt.setdef(tsetdef.create(tt2,torddef(tt2.def).high))
  517. else
  518. Message(sym_e_ill_type_decl_set);
  519. end;
  520. else
  521. Message(sym_e_ill_type_decl_set);
  522. end;
  523. end;
  524. else
  525. Message(sym_e_ill_type_decl_set);
  526. end;
  527. end
  528. else
  529. tt:=generrortype;
  530. end;
  531. _CARET:
  532. begin
  533. consume(_CARET);
  534. single_type(tt2,hs,typecanbeforward);
  535. tt.setdef(tpointerdef.create(tt2));
  536. end;
  537. _RECORD:
  538. begin
  539. tt.setdef(record_dec);
  540. end;
  541. _PACKED:
  542. begin
  543. consume(_PACKED);
  544. if token=_ARRAY then
  545. array_dec
  546. else
  547. begin
  548. oldaktpackrecords:=aktalignment.recordalignmax;
  549. aktalignment.recordalignmax:=1;
  550. if token in [_CLASS,_OBJECT] then
  551. tt.setdef(object_dec(name,nil))
  552. else
  553. tt.setdef(record_dec);
  554. aktalignment.recordalignmax:=oldaktpackrecords;
  555. end;
  556. end;
  557. _CLASS,
  558. _CPPCLASS,
  559. _INTERFACE,
  560. _OBJECT:
  561. begin
  562. tt.setdef(object_dec(name,nil));
  563. end;
  564. _PROCEDURE:
  565. begin
  566. consume(_PROCEDURE);
  567. tt.setdef(tprocvardef.create);
  568. if token=_LKLAMMER then
  569. parameter_dec(tprocvardef(tt.def));
  570. if token=_OF then
  571. begin
  572. consume(_OF);
  573. consume(_OBJECT);
  574. include(tprocvardef(tt.def).procoptions,po_methodpointer);
  575. end;
  576. end;
  577. _FUNCTION:
  578. begin
  579. consume(_FUNCTION);
  580. tt.def:=tprocvardef.create;
  581. if token=_LKLAMMER then
  582. parameter_dec(tprocvardef(tt.def));
  583. consume(_COLON);
  584. single_type(tprocvardef(tt.def).rettype,hs,false);
  585. if token=_OF then
  586. begin
  587. consume(_OF);
  588. consume(_OBJECT);
  589. include(tprocvardef(tt.def).procoptions,po_methodpointer);
  590. end;
  591. end;
  592. else
  593. expr_type;
  594. end;
  595. if tt.def=nil then
  596. tt:=generrortype;
  597. end;
  598. end.
  599. {
  600. $Log$
  601. Revision 1.36 2002-04-16 16:12:47 peter
  602. * give error when using enums with jumps as array index
  603. * allow char as enum value
  604. Revision 1.35 2002/04/04 19:06:04 peter
  605. * removed unused units
  606. * use tlocation.size in cg.a_*loc*() routines
  607. Revision 1.34 2002/01/24 18:25:49 peter
  608. * implicit result variable generation for assembler routines
  609. * removed m_tp modeswitch, use m_tp7 or not(m_fpc) instead
  610. Revision 1.33 2002/01/15 16:13:34 jonas
  611. * fixed web bugs 1758 and 1760
  612. Revision 1.32 2002/01/06 12:08:15 peter
  613. * removed uauto from orddef, use new range_to_basetype generating
  614. the correct ordinal type for a range
  615. Revision 1.30 2001/08/30 20:13:53 peter
  616. * rtti/init table updates
  617. * rttisym for reusable global rtti/init info
  618. * support published for interfaces
  619. Revision 1.29 2001/08/12 22:10:16 peter
  620. * write name in original case when type not found
  621. Revision 1.28 2001/07/09 21:15:41 peter
  622. * Length made internal
  623. * Add array support for Length
  624. Revision 1.27 2001/07/01 20:16:16 peter
  625. * alignmentinfo record added
  626. * -Oa argument supports more alignment settings that can be specified
  627. per type: PROC,LOOP,VARMIN,VARMAX,CONSTMIN,CONSTMAX,RECORDMIN
  628. RECORDMAX,LOCALMIN,LOCALMAX. It is possible to set the mimimum
  629. required alignment and the maximum usefull alignment. The final
  630. alignment will be choosen per variable size dependent on these
  631. settings
  632. Revision 1.26 2001/06/04 18:06:38 peter
  633. * fix for enum with assignment
  634. Revision 1.25 2001/06/04 11:51:59 peter
  635. * enum type declarations assignments can also be of the same enum
  636. type
  637. Revision 1.24 2001/06/03 20:16:19 peter
  638. * allow int64 in range declaration for new types
  639. Revision 1.23 2001/04/13 01:22:13 peter
  640. * symtable change to classes
  641. * range check generation and errors fixed, make cycle DEBUG=1 works
  642. * memory leaks fixed
  643. Revision 1.22 2001/04/04 22:43:53 peter
  644. * remove unnecessary calls to firstpass
  645. Revision 1.21 2001/04/02 21:20:34 peter
  646. * resulttype rewrite
  647. Revision 1.20 2001/03/22 22:35:42 florian
  648. + support for type a = (a=1); in Delphi mode added
  649. + procedure p(); in Delphi mode supported
  650. + on isn't keyword anymore, it can be used as
  651. id etc. now
  652. Revision 1.19 2001/03/12 12:49:01 michael
  653. + Patches from peter
  654. Revision 1.18 2001/03/11 22:58:50 peter
  655. * getsym redesign, removed the globals srsym,srsymtable
  656. Revision 1.17 2000/12/07 17:19:43 jonas
  657. * new constant handling: from now on, hex constants >$7fffffff are
  658. parsed as unsigned constants (otherwise, $80000000 got sign extended
  659. and became $ffffffff80000000), all constants in the longint range
  660. become longints, all constants >$7fffffff and <=cardinal($ffffffff)
  661. are cardinals and the rest are int64's.
  662. * added lots of longint typecast to prevent range check errors in the
  663. compiler and rtl
  664. * type casts of symbolic ordinal constants are now preserved
  665. * fixed bug where the original resulttype.def wasn't restored correctly
  666. after doing a 64bit rangecheck
  667. Revision 1.16 2000/11/29 00:30:38 florian
  668. * unused units removed from uses clause
  669. * some changes for widestrings
  670. Revision 1.15 2000/11/14 23:43:38 florian
  671. * fixed 1238
  672. Revision 1.14 2000/11/04 14:25:21 florian
  673. + merged Attila's changes for interfaces, not tested yet
  674. Revision 1.13 2000/10/31 22:02:51 peter
  675. * symtable splitted, no real code changes
  676. Revision 1.12 2000/10/26 21:54:03 peter
  677. * fixed crash with error in child definition (merged)
  678. Revision 1.11 2000/10/21 18:16:12 florian
  679. * a lot of changes:
  680. - basic dyn. array support
  681. - basic C++ support
  682. - some work for interfaces done
  683. ....
  684. Revision 1.10 2000/10/14 10:14:52 peter
  685. * moehrendorf oct 2000 rewrite
  686. Revision 1.9 2000/09/24 15:06:25 peter
  687. * use defines.inc
  688. Revision 1.8 2000/08/27 20:19:39 peter
  689. * store strings with case in ppu, when an internal symbol is created
  690. a '$' is prefixed so it's not automatic uppercased
  691. Revision 1.7 2000/08/27 16:11:52 peter
  692. * moved some util functions from globals,cobjects to cutils
  693. * splitted files into finput,fmodule
  694. Revision 1.6 2000/08/16 18:33:54 peter
  695. * splitted namedobjectitem.next into indexnext and listnext so it
  696. can be used in both lists
  697. * don't allow "word = word" type definitions (merged)
  698. Revision 1.5 2000/08/06 14:17:15 peter
  699. * overload fixes (merged)
  700. Revision 1.4 2000/07/30 17:04:43 peter
  701. * merged fixes
  702. Revision 1.3 2000/07/13 12:08:27 michael
  703. + patched to 1.1.0 with former 1.09patch from peter
  704. Revision 1.2 2000/07/13 11:32:47 michael
  705. + removed logs
  706. }