ptype.pas 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717
  1. {
  2. $Id$
  3. Copyright (c) 1998-2002 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 fpcdefs.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,
  43. { global }
  44. globals,tokens,verbose,
  45. systems,
  46. { symtable }
  47. symconst,symbase,symdef,symsym,symtable,
  48. defutil,defcmp,
  49. { pass 1 }
  50. node,
  51. nmat,nadd,ncal,nset,ncnv,ninl,ncon,nld,nflw,
  52. { parser }
  53. scanner,
  54. pbase,pexpr,pdecsub,pdecvar,pdecobj;
  55. procedure id_type(var tt : ttype;var s : string;isforwarddef:boolean);
  56. { reads a type definition }
  57. { to a appropriating tdef, s gets the name of }
  58. { the type to allow name mangling }
  59. var
  60. is_unit_specific : boolean;
  61. pos : tfileposinfo;
  62. srsym : tsym;
  63. srsymtable : tsymtable;
  64. sorg : stringid;
  65. begin
  66. s:=pattern;
  67. sorg:=orgpattern;
  68. pos:=akttokenpos;
  69. { classes can be used also in classes }
  70. if (curobjectname=pattern) and is_class_or_interface(aktobjectdef) then
  71. begin
  72. tt.setdef(aktobjectdef);
  73. consume(_ID);
  74. exit;
  75. end;
  76. { objects can be parameters }
  77. if (testcurobject=2) and (curobjectname=pattern) then
  78. begin
  79. tt.setdef(aktobjectdef);
  80. consume(_ID);
  81. exit;
  82. end;
  83. { try to load the symbol to see if it's a unitsym }
  84. is_unit_specific:=false;
  85. searchsym(s,srsym,srsymtable);
  86. consume(_ID);
  87. if assigned(srsym) and
  88. (srsym.typ=unitsym) then
  89. begin
  90. is_unit_specific:=true;
  91. consume(_POINT);
  92. if srsym.owner.unitid=0 then
  93. begin
  94. srsym:=searchsymonlyin(tunitsym(srsym).unitsymtable,pattern);
  95. pos:=akttokenpos;
  96. s:=pattern;
  97. end
  98. else
  99. srsym:=nil;
  100. consume(_ID);
  101. end;
  102. { Types are first defined with an error def before assigning
  103. the real type so check if it's an errordef. if so then
  104. give an error. Only check for typesyms in the current symbol
  105. table as forwarddef are not resolved directly }
  106. if assigned(srsym) and
  107. (srsym.typ=typesym) and
  108. (srsym.owner=symtablestack) and
  109. (ttypesym(srsym).restype.def.deftype=errordef) then
  110. begin
  111. Message1(type_e_type_is_not_completly_defined,ttypesym(srsym).realname);
  112. tt:=generrortype;
  113. exit;
  114. end;
  115. { are we parsing a possible forward def ? }
  116. if isforwarddef and
  117. not(is_unit_specific) then
  118. begin
  119. tt.setdef(tforwarddef.create(s,pos));
  120. exit;
  121. end;
  122. { unknown sym ? }
  123. if not assigned(srsym) then
  124. begin
  125. Message1(sym_e_id_not_found,sorg);
  126. tt:=generrortype;
  127. exit;
  128. end;
  129. { type sym ? }
  130. if (srsym.typ<>typesym) then
  131. begin
  132. Message(type_e_type_id_expected);
  133. tt:=generrortype;
  134. exit;
  135. end;
  136. { Give an error when referring to an errordef }
  137. if (ttypesym(srsym).restype.def.deftype=errordef) then
  138. begin
  139. Message(sym_e_error_in_type_def);
  140. tt:=generrortype;
  141. exit;
  142. end;
  143. { Only use the definitions for current unit, becuase
  144. they can be refered from the parameters and symbols are not
  145. loaded at that time. A symbol reference to an other unit
  146. is still possible, because it's already loaded (PFV)
  147. can't use in [] here, becuase unitid can be > 255 }
  148. if (ttypesym(srsym).owner.unitid=0) then
  149. tt.setdef(ttypesym(srsym).restype.def)
  150. else
  151. tt.setsym(srsym);
  152. end;
  153. procedure single_type(var tt:ttype;var s : string;isforwarddef:boolean);
  154. { reads a string, file type or a type id and returns a name and }
  155. { tdef }
  156. var
  157. hs : string;
  158. t2 : ttype;
  159. begin
  160. case token of
  161. _STRING:
  162. begin
  163. string_dec(tt);
  164. s:='STRING';
  165. end;
  166. _FILE:
  167. begin
  168. consume(_FILE);
  169. if token=_OF then
  170. begin
  171. consume(_OF);
  172. single_type(t2,hs,false);
  173. tt.setdef(tfiledef.createtyped(t2));
  174. s:='FILE$OF$'+hs;
  175. end
  176. else
  177. begin
  178. tt:=cfiletype;
  179. s:='FILE';
  180. end;
  181. end;
  182. _ID:
  183. begin
  184. id_type(tt,s,isforwarddef);
  185. end;
  186. else
  187. begin
  188. message(type_e_type_id_expected);
  189. s:='<unknown>';
  190. tt:=generrortype;
  191. end;
  192. end;
  193. end;
  194. { reads a record declaration }
  195. function record_dec : tdef;
  196. var
  197. symtable : tsymtable;
  198. storetypecanbeforward : boolean;
  199. old_object_option : tsymoptions;
  200. begin
  201. { create recdef }
  202. symtable:=trecordsymtable.create;
  203. record_dec:=trecorddef.create(symtable);
  204. { update symtable stack }
  205. symtable.next:=symtablestack;
  206. symtablestack:=symtable;
  207. { parse record }
  208. consume(_RECORD);
  209. old_object_option:=current_object_option;
  210. current_object_option:=[sp_public];
  211. storetypecanbeforward:=typecanbeforward;
  212. { for tp7 don't allow forward types }
  213. if m_tp7 in aktmodeswitches then
  214. typecanbeforward:=false;
  215. read_var_decs(true,false,false);
  216. consume(_END);
  217. typecanbeforward:=storetypecanbeforward;
  218. current_object_option:=old_object_option;
  219. { may be scale record size to a size of n*4 ? }
  220. symtablestack.datasize:=align(symtablestack.datasize,symtablestack.dataalignment);
  221. { restore symtable stack }
  222. symtablestack:=symtable.next;
  223. end;
  224. { reads a type definition and returns a pointer to it }
  225. procedure read_type(var tt : ttype;const name : stringid);
  226. var
  227. pt : tnode;
  228. tt2 : ttype;
  229. aktenumdef : tenumdef;
  230. ap : tarraydef;
  231. s : stringid;
  232. l,v : TConstExprInt;
  233. oldaktpackrecords : longint;
  234. hs : string;
  235. defpos,storepos : tfileposinfo;
  236. procedure expr_type;
  237. var
  238. pt1,pt2 : tnode;
  239. lv,hv : TConstExprInt;
  240. begin
  241. { use of current parsed object ? }
  242. if (token=_ID) and (testcurobject=2) and (curobjectname=pattern) then
  243. begin
  244. consume(_ID);
  245. tt.setdef(aktobjectdef);
  246. exit;
  247. end;
  248. { classes can be used also in classes }
  249. if (curobjectname=pattern) and is_class_or_interface(aktobjectdef) then
  250. begin
  251. tt.setdef(aktobjectdef);
  252. consume(_ID);
  253. exit;
  254. end;
  255. { we can't accept a equal in type }
  256. pt1:=comp_expr(not(ignore_equal));
  257. if (token=_POINTPOINT) then
  258. begin
  259. consume(_POINTPOINT);
  260. { get high value of range }
  261. pt2:=comp_expr(not(ignore_equal));
  262. { make both the same type }
  263. inserttypeconv(pt1,pt2.resulttype);
  264. { both must be evaluated to constants now }
  265. if (pt1.nodetype=ordconstn) and
  266. (pt2.nodetype=ordconstn) then
  267. begin
  268. lv:=tordconstnode(pt1).value;
  269. hv:=tordconstnode(pt2).value;
  270. { Check bounds }
  271. if hv<lv then
  272. Message(cg_e_upper_lower_than_lower)
  273. else
  274. begin
  275. { All checks passed, create the new def }
  276. case pt1.resulttype.def.deftype of
  277. enumdef :
  278. tt.setdef(tenumdef.create_subrange(tenumdef(pt1.resulttype.def),lv,hv));
  279. orddef :
  280. begin
  281. if is_char(pt1.resulttype.def) then
  282. tt.setdef(torddef.create(uchar,lv,hv))
  283. else
  284. if is_boolean(pt1.resulttype.def) then
  285. tt.setdef(torddef.create(bool8bit,l,hv))
  286. else
  287. tt.setdef(torddef.create(range_to_basetype(lv,hv),lv,hv));
  288. end;
  289. end;
  290. end;
  291. end
  292. else
  293. Message(sym_e_error_in_type_def);
  294. pt2.free;
  295. end
  296. else
  297. begin
  298. { a simple type renaming }
  299. if (pt1.nodetype=typen) then
  300. tt:=ttypenode(pt1).resulttype
  301. else
  302. Message(sym_e_error_in_type_def);
  303. end;
  304. pt1.free;
  305. end;
  306. procedure array_dec;
  307. var
  308. lowval,
  309. highval : longint;
  310. arraytype : ttype;
  311. ht : ttype;
  312. procedure setdefdecl(const t:ttype);
  313. begin
  314. case t.def.deftype of
  315. enumdef :
  316. begin
  317. lowval:=tenumdef(t.def).min;
  318. highval:=tenumdef(t.def).max;
  319. if tenumdef(t.def).has_jumps then
  320. Message(type_e_array_index_enums_with_assign_not_possible);
  321. arraytype:=t;
  322. end;
  323. orddef :
  324. begin
  325. if torddef(t.def).typ in [uchar,
  326. u8bit,u16bit,
  327. s8bit,s16bit,s32bit,
  328. bool8bit,bool16bit,bool32bit,
  329. uwidechar] then
  330. begin
  331. lowval:=torddef(t.def).low;
  332. highval:=torddef(t.def).high;
  333. arraytype:=t;
  334. end
  335. else
  336. Message1(parser_e_type_cant_be_used_in_array_index,t.def.gettypename);
  337. end;
  338. else
  339. Message(sym_e_error_in_type_def);
  340. end;
  341. end;
  342. begin
  343. consume(_ARRAY);
  344. { open array? }
  345. if token=_LECKKLAMMER then
  346. begin
  347. consume(_LECKKLAMMER);
  348. { defaults }
  349. arraytype:=generrortype;
  350. lowval:=longint($80000000);
  351. highval:=$7fffffff;
  352. tt.reset;
  353. repeat
  354. { read the expression and check it, check apart if the
  355. declaration is an enum declaration because that needs to
  356. be parsed by readtype (PFV) }
  357. if token=_LKLAMMER then
  358. begin
  359. read_type(ht,'');
  360. setdefdecl(ht);
  361. end
  362. else
  363. begin
  364. pt:=expr;
  365. if pt.nodetype=typen then
  366. setdefdecl(pt.resulttype)
  367. else
  368. begin
  369. if (pt.nodetype=rangen) then
  370. begin
  371. if (trangenode(pt).left.nodetype=ordconstn) and
  372. (trangenode(pt).right.nodetype=ordconstn) then
  373. begin
  374. lowval:=tordconstnode(trangenode(pt).left).value;
  375. highval:=tordconstnode(trangenode(pt).right).value;
  376. if highval<lowval then
  377. begin
  378. Message(parser_e_array_lower_less_than_upper_bound);
  379. highval:=lowval;
  380. end;
  381. arraytype:=trangenode(pt).right.resulttype;
  382. end
  383. else
  384. Message(type_e_cant_eval_constant_expr);
  385. end
  386. else
  387. Message(sym_e_error_in_type_def)
  388. end;
  389. pt.free;
  390. end;
  391. { create arraydef }
  392. if not assigned(tt.def) then
  393. begin
  394. ap:=tarraydef.create(lowval,highval,arraytype);
  395. tt.setdef(ap);
  396. end
  397. else
  398. begin
  399. ap.elementtype.setdef(tarraydef.create(lowval,highval,arraytype));
  400. ap:=tarraydef(ap.elementtype.def);
  401. end;
  402. if token=_COMMA then
  403. consume(_COMMA)
  404. else
  405. break;
  406. until false;
  407. consume(_RECKKLAMMER);
  408. end
  409. else
  410. begin
  411. ap:=tarraydef.create(0,-1,s32bittype);
  412. ap.IsDynamicArray:=true;
  413. tt.setdef(ap);
  414. end;
  415. consume(_OF);
  416. read_type(tt2,'');
  417. { if no error, set element type }
  418. if assigned(ap) then
  419. ap.setelementtype(tt2);
  420. end;
  421. var
  422. p : tnode;
  423. enumdupmsg : boolean;
  424. begin
  425. tt.reset;
  426. case token of
  427. _STRING,_FILE:
  428. begin
  429. single_type(tt,hs,false);
  430. end;
  431. _LKLAMMER:
  432. begin
  433. consume(_LKLAMMER);
  434. { allow negativ value_str }
  435. l:=-1;
  436. enumdupmsg:=false;
  437. aktenumdef:=tenumdef.create;
  438. repeat
  439. s:=orgpattern;
  440. defpos:=akttokenpos;
  441. consume(_ID);
  442. { only allow assigning of specific numbers under fpc mode }
  443. if (m_fpc in aktmodeswitches) and
  444. (token=_ASSIGNMENT) then
  445. begin
  446. consume(_ASSIGNMENT);
  447. p:=comp_expr(true);
  448. if (p.nodetype=ordconstn) then
  449. begin
  450. { we expect an integer or an enum of the
  451. same type }
  452. if is_integer(p.resulttype.def) or
  453. is_char(p.resulttype.def) or
  454. equal_defs(p.resulttype.def,aktenumdef) then
  455. v:=tordconstnode(p).value
  456. else
  457. Message2(type_e_incompatible_types,p.resulttype.def.typename,s32bittype.def.typename);
  458. end
  459. else
  460. Message(cg_e_illegal_expression);
  461. p.free;
  462. { please leave that a note, allows type save }
  463. { declarations in the win32 units ! }
  464. if (v<=l) and (not enumdupmsg) then
  465. begin
  466. Message(parser_n_duplicate_enum);
  467. enumdupmsg:=true;
  468. end;
  469. l:=v;
  470. end
  471. else if (m_delphi in aktmodeswitches) and
  472. (token=_EQUAL) then
  473. begin
  474. consume(_EQUAL);
  475. p:=comp_expr(true);
  476. if (p.nodetype=ordconstn) then
  477. begin
  478. { we expect an integer or an enum of the
  479. same type }
  480. if is_integer(p.resulttype.def) or
  481. equal_defs(p.resulttype.def,aktenumdef) then
  482. l:=tordconstnode(p).value
  483. else
  484. Message2(type_e_incompatible_types,p.resulttype.def.typename,s32bittype.def.typename);
  485. end
  486. else
  487. Message(cg_e_illegal_expression);
  488. p.free;
  489. end
  490. else
  491. inc(l);
  492. storepos:=akttokenpos;
  493. akttokenpos:=defpos;
  494. constsymtable.insert(tenumsym.create(s,aktenumdef,l));
  495. akttokenpos:=storepos;
  496. until not try_to_consume(_COMMA);
  497. tt.setdef(aktenumdef);
  498. consume(_RKLAMMER);
  499. end;
  500. _ARRAY:
  501. begin
  502. array_dec;
  503. end;
  504. _SET:
  505. begin
  506. consume(_SET);
  507. consume(_OF);
  508. read_type(tt2,'');
  509. if assigned(tt2.def) then
  510. begin
  511. case tt2.def.deftype of
  512. { don't forget that min can be negativ PM }
  513. enumdef :
  514. if tenumdef(tt2.def).min>=0 then
  515. tt.setdef(tsetdef.create(tt2,tenumdef(tt2.def).max))
  516. else
  517. Message(sym_e_ill_type_decl_set);
  518. orddef :
  519. begin
  520. case torddef(tt2.def).typ of
  521. uchar :
  522. tt.setdef(tsetdef.create(tt2,255));
  523. u8bit,u16bit,u32bit,
  524. s8bit,s16bit,s32bit :
  525. begin
  526. if (torddef(tt2.def).low>=0) then
  527. tt.setdef(tsetdef.create(tt2,torddef(tt2.def).high))
  528. else
  529. Message(sym_e_ill_type_decl_set);
  530. end;
  531. else
  532. Message(sym_e_ill_type_decl_set);
  533. end;
  534. end;
  535. else
  536. Message(sym_e_ill_type_decl_set);
  537. end;
  538. end
  539. else
  540. tt:=generrortype;
  541. end;
  542. _CARET:
  543. begin
  544. consume(_CARET);
  545. single_type(tt2,hs,typecanbeforward);
  546. tt.setdef(tpointerdef.create(tt2));
  547. end;
  548. _RECORD:
  549. begin
  550. tt.setdef(record_dec);
  551. end;
  552. _PACKED:
  553. begin
  554. consume(_PACKED);
  555. if token=_ARRAY then
  556. array_dec
  557. else
  558. begin
  559. oldaktpackrecords:=aktalignment.recordalignmax;
  560. aktalignment.recordalignmax:=1;
  561. if token in [_CLASS,_OBJECT] then
  562. tt.setdef(object_dec(name,nil))
  563. else
  564. tt.setdef(record_dec);
  565. aktalignment.recordalignmax:=oldaktpackrecords;
  566. end;
  567. end;
  568. _CLASS,
  569. _CPPCLASS,
  570. _INTERFACE,
  571. _OBJECT:
  572. begin
  573. tt.setdef(object_dec(name,nil));
  574. end;
  575. _PROCEDURE:
  576. begin
  577. consume(_PROCEDURE);
  578. tt.setdef(tprocvardef.create);
  579. if token=_LKLAMMER then
  580. parameter_dec(tprocvardef(tt.def));
  581. if token=_OF then
  582. begin
  583. consume(_OF);
  584. consume(_OBJECT);
  585. include(tprocvardef(tt.def).procoptions,po_methodpointer);
  586. end;
  587. end;
  588. _FUNCTION:
  589. begin
  590. consume(_FUNCTION);
  591. tt.def:=tprocvardef.create;
  592. if token=_LKLAMMER then
  593. parameter_dec(tprocvardef(tt.def));
  594. consume(_COLON);
  595. single_type(tprocvardef(tt.def).rettype,hs,false);
  596. if token=_OF then
  597. begin
  598. consume(_OF);
  599. consume(_OBJECT);
  600. include(tprocvardef(tt.def).procoptions,po_methodpointer);
  601. end;
  602. end;
  603. else
  604. expr_type;
  605. end;
  606. if tt.def=nil then
  607. tt:=generrortype;
  608. end;
  609. end.
  610. {
  611. $Log$
  612. Revision 1.46 2002-11-25 17:43:23 peter
  613. * splitted defbase in defutil,symutil,defcmp
  614. * merged isconvertable and is_equal into compare_defs(_ext)
  615. * made operator search faster by walking the list only once
  616. Revision 1.45 2002/09/27 21:13:29 carl
  617. * low-highval always checked if limit ober 2GB is reached (to avoid overflow)
  618. Revision 1.44 2002/09/10 16:26:39 peter
  619. * safety check for typesym added for incomplete type def check
  620. Revision 1.43 2002/09/09 19:34:07 peter
  621. * check for incomplete types in the current symtable when parsing
  622. forwarddef. Maybe this shall be delphi/tp only
  623. Revision 1.42 2002/07/20 11:57:56 florian
  624. * types.pas renamed to defbase.pas because D6 contains a types
  625. unit so this would conflicts if D6 programms are compiled
  626. + Willamette/SSE2 instructions to assembler added
  627. Revision 1.41 2002/05/18 13:34:16 peter
  628. * readded missing revisions
  629. Revision 1.40 2002/05/16 19:46:44 carl
  630. + defines.inc -> fpcdefs.inc to avoid conflicts if compiling by hand
  631. + try to fix temp allocation (still in ifdef)
  632. + generic constructor calls
  633. + start of tassembler / tmodulebase class cleanup
  634. Revision 1.38 2002/05/12 16:53:10 peter
  635. * moved entry and exitcode to ncgutil and cgobj
  636. * foreach gets extra argument for passing local data to the
  637. iterator function
  638. * -CR checks also class typecasts at runtime by changing them
  639. into as
  640. * fixed compiler to cycle with the -CR option
  641. * fixed stabs with elf writer, finally the global variables can
  642. be watched
  643. * removed a lot of routines from cga unit and replaced them by
  644. calls to cgobj
  645. * u32bit-s32bit updates for and,or,xor nodes. When one element is
  646. u32bit then the other is typecasted also to u32bit without giving
  647. a rangecheck warning/error.
  648. * fixed pascal calling method with reversing also the high tree in
  649. the parast, detected by tcalcst3 test
  650. Revision 1.37 2002/04/19 15:46:03 peter
  651. * mangledname rewrite, tprocdef.mangledname is now created dynamicly
  652. in most cases and not written to the ppu
  653. * add mangeledname_prefix() routine to generate the prefix of
  654. manglednames depending on the current procedure, object and module
  655. * removed static procprefix since the mangledname is now build only
  656. on demand from tprocdef.mangledname
  657. Revision 1.36 2002/04/16 16:12:47 peter
  658. * give error when using enums with jumps as array index
  659. * allow char as enum value
  660. Revision 1.35 2002/04/04 19:06:04 peter
  661. * removed unused units
  662. * use tlocation.size in cg.a_*loc*() routines
  663. Revision 1.34 2002/01/24 18:25:49 peter
  664. * implicit result variable generation for assembler routines
  665. * removed m_tp modeswitch, use m_tp7 or not(m_fpc) instead
  666. Revision 1.33 2002/01/15 16:13:34 jonas
  667. * fixed web bugs 1758 and 1760
  668. Revision 1.32 2002/01/06 12:08:15 peter
  669. * removed uauto from orddef, use new range_to_basetype generating
  670. the correct ordinal type for a range
  671. }