Commit Graph

136 Commits

Author SHA1 Message Date
Jonas Maebe
e1aefdbac5 * Improved escape analysis so the improved tretopt no longer fails.
The downside is that because it is context-insensitive, several
    (correct) optimizations which were performed in the past no longer
    are now (and while some new ones are done now, the downside is bigger
    -- but at least the code should be correct in all cases now)

git-svn-id: trunk@8385 -
2007-09-05 13:29:22 +00:00
Jonas Maebe
ce478cd249 * fixed wrong range check warnings/errors for open strings
git-svn-id: trunk@7944 -
2007-07-04 08:09:45 +00:00
daniel
bbf7c50479 + Internalerror on encountering a variant array in a vecn.
git-svn-id: trunk@7936 -
2007-07-03 19:58:47 +00:00
daniel
06b3478226 * Fix tarray7
* Use is_special_array.

git-svn-id: trunk@7932 -
2007-07-03 13:35:15 +00:00
daniel
a0da139ec6 * Fix most test suite regressions.
git-svn-id: trunk@7931 -
2007-07-03 11:31:46 +00:00
daniel
4ed25e3a78 * Fix tbs/tb0540.
git-svn-id: trunk@7926 -
2007-07-02 21:32:27 +00:00
daniel
9adb202a92 * Rework the constexprint to allow operations from low(int64) to high(qword).
+ Some initial work on a formaldef which also carries the typinfo of a parameter.

git-svn-id: trunk@7639 -
2007-06-13 07:41:18 +00:00
Jonas Maebe
4ce4742bc8 * mark invisible high parameters of open arrays/arrays of const
of parent procedures which are implicitly accessed from within
    nested procedures for range checking purposes as non-regable in
    the resulttype pass of the nested procedure (as opposed to in its
    pass1/pass2, because by then the regvar assignment of the parent
    procedure is already finished) (mantis #8975)
  * related fix regarding checking whether the high parameter actually
    exists (must check calling convention of the procedure to which the
    high parameter belongs, which is not the same as checking that of
    the current procedure in case of nested procedures)

git-svn-id: trunk@7512 -
2007-05-29 13:42:49 +00:00
Jonas Maebe
f2b07704b5 * proper initialised/used warnings for variables used
in complex with-statements + tests

git-svn-id: trunk@6024 -
2007-01-17 12:04:53 +00:00
Jonas Maebe
9ad579855e * fixed webtbf/tw3631
* properly set vs_read/written status for tp-style objects
    without vmt of which a method is called

git-svn-id: trunk@6005 -
2007-01-16 21:15:21 +00:00
peter
0557ddc342 * removed typed const, it is now handled by staticvarsym
* globalvarsym renamed to staticvarsym
  * fixed invalid regvar use in init when the finalize also uses the var

git-svn-id: trunk@5290 -
2006-11-08 21:04:22 +00:00
peter
658c46b903 * remove tdictionary and tindexarray
* symtables based on TFPHashObjectList and TFPObjectList
  * rename torddef.typ to torddef.ordtype
  * rename tfloatdef.typ to tfloatdef.floattype
  * rename tdef.deftype to tdef.typ
  * remove obsolete browser code, browcol is kept so the ide
    can still be compiled

git-svn-id: trunk@5192 -
2006-11-03 00:30:30 +00:00
florian
ef7bd58c54 * germanism removed (aktfilepos -> current_filepos)
git-svn-id: trunk@5099 -
2006-10-30 22:37:31 +00:00
florian
85d63d9fa9 * settings refactored
git-svn-id: trunk@5094 -
2006-10-30 18:02:58 +00:00
peter
3078a1927f * remove ttype
* rename old ttype variables *type to *def
  * rename resulttypepass to pass_typecheck
  * rename pass_2 to pass_generate_code

git-svn-id: trunk@5077 -
2006-10-29 22:19:39 +00:00
daniel
67851f6aba + arrayvar[l..h] now valid parameter for open array.
git-svn-id: trunk@5064 -
2006-10-29 17:45:09 +00:00
daniel
de423ab5b0 + stringvar[l..h] now valid parameter for open array of char.
git-svn-id: trunk@5038 -
2006-10-27 22:23:25 +00:00
daniel
2450f5a778 + First working concept of open_array_procedure(Pbyte_var[0..9]);
git-svn-id: trunk@5028 -
2006-10-26 20:30:16 +00:00
micha
8678d52aeb * avoid warning when pointer points to size 1 data
* fix variantmanager for {$T+}

git-svn-id: trunk@4861 -
2006-10-11 16:40:40 +00:00
peter
2f0ce31751 * string concat changed from function to procedure to
allow runtime optimization if the destination is the
    same as a source parameter
  * tassignmentnode now sets aktassignmentnode global that can be used
    to use the left node as a destination parameter and
    skip the assignment
  * disabled all cpu specific shortstr concat/append

git-svn-id: trunk@4770 -
2006-10-02 20:00:06 +00:00
Jonas Maebe
1ab3d81541 * also use LOC_CSUBSETREF
* set expectloc properly for packed arrays

git-svn-id: trunk@4480 -
2006-08-20 19:28:10 +00:00
Jonas Maebe
6dde68da3a * fix IE when subscripting records part of another record regvar
git-svn-id: trunk@3613 -
2006-05-21 16:04:14 +00:00
Jonas Maebe
84d1fc929f * properly set regvarability of parameters and local variables of inlined
functions
  * fixed setting of expectloc for fields of regvar'ed records

git-svn-id: trunk@3607 -
2006-05-20 23:37:55 +00:00
Jonas Maebe
e344ee3cd7 + support for register variables which contain records
git-svn-id: trunk@3580 -
2006-05-19 15:49:07 +00:00
Jonas Maebe
e0250bcdb4 * never remove regvar-ability of parameters passed by reference
(previously worked only for var/out, now also for const and
     is more generic)

git-svn-id: trunk@3554 -
2006-05-17 13:38:02 +00:00
florian
570c1bc3a5 * widestrings aren't ref. counted anymore on windows
git-svn-id: trunk@3466 -
2006-05-09 20:54:26 +00:00
Jonas Maebe
f59d552ecb * fixed web bug #4913 (don't allow indexing of strings/variants/pointers
with enums/chars/booleans)

git-svn-id: trunk@2952 -
2006-03-18 11:05:04 +00:00
peter
232555904e * symtablestack cleanup and rewrite
git-svn-id: trunk@2448 -
2006-02-05 22:24:18 +00:00
peter
45176ea2a8 * split tstringtype for stringdef and stringconstnode
to prevent wrong typecasts

git-svn-id: trunk@2276 -
2006-01-13 17:20:27 +00:00
Jonas Maebe
857664a5d4 * fixed tw4554:
* proper uninitialized checking for arrays
    * first check uninitialized status of right side of assignment
      before setting the left side to "written" (-> catch "x:=x" if
      x is uninitialized)

git-svn-id: trunk@2038 -
2005-12-23 21:08:48 +00:00
peter
95879fe8a7 * basic support for generic classes
git-svn-id: trunk@2020 -
2005-12-21 10:11:15 +00:00
Jonas Maebe
42ec76598c * new categories for vs_*: vs_declared, vs_initialised, vs_read,
vs_written, vs_readwritten. vs_initialised is the old vs_assigned;
    vs_used has been replaced by vs_read, vs_written and vs_readwritten
  * the valid_for_*() routines in htypechk now get an extra parameter to
    decide whether or not errors should be reported

git-svn-id: trunk@1913 -
2005-12-10 16:51:26 +00:00
peter
45fbeaad53 * implicitly convert constant string to stringdef if it is indexed
git-svn-id: trunk@1468 -
2005-10-18 10:52:43 +00:00
peter
89297d2c39 * move all stabs ($ifdef gdb) code to dbgstabs
git-svn-id: trunk@1255 -
2005-10-02 11:17:05 +00:00
peter
05c241072e * allow widechar for indexing arrays, fixes 4115
git-svn-id: trunk@497 -
2005-06-25 21:06:53 +00:00
florian
7cd67ea3f0 * node optimizer branch merged
* gotonode and gotolabel refactored
  * -Nu added to enable for loop unrolling

git-svn-id: trunk@446 -
2005-06-19 17:42:10 +00:00
florian
c4449e9c26 - unnecessary check in taddrnode.pass_1 removed, fixes bug #4010
git-svn-id: trunk@426 -
2005-06-16 17:12:51 +00:00
florian
8994c6362c * arrays now use the native int type as index
git-svn-id: trunk@48 -
2005-05-21 14:48:15 +00:00
fpc
790a4fe2d3 * log and id tags removed
git-svn-id: trunk@42 -
2005-05-21 09:42:41 +00:00
fpc
50778076c3 initial import
git-svn-id: trunk@1 -
2005-05-16 18:37:41 +00:00
florian
e33bf907d8 * fixed previous commit 2005-04-06 19:39:04 +00:00
peter
3f9d6ab32f * add hint when passing an uninitialized variable to a var parameter 2005-03-25 22:20:18 +00:00
peter
e417e34496 * truncate log 2005-02-14 17:13:06 +00:00
peter
ced6bf20cd * fix lineinfo for with blocks 2004-12-26 16:22:01 +00:00
peter
2b6456fe16 * procvar handling for tp procvar mode fixed
* proc to procvar moved from addrnode to typeconvnode
  * inlininginfo is now allocated only for inline routines that
    can be inlined, introduced a new flag po_has_inlining_info
2004-12-05 12:28:10 +00:00
peter
5f61be6b4d * prevent some IEs with delphi methodpointers 2004-11-29 17:32:56 +00:00
peter
b55fe3fa67 * don't allow @method in tp procvar mode 2004-11-26 22:33:24 +00:00
peter
e740a66636 * tparaitem removed, use tparavarsym instead
* parameter order is now calculated from paranr value in tparavarsym
2004-11-15 23:35:30 +00:00
peter
6458bd0ce1 * tvarsym splitted 2004-11-08 22:09:58 +00:00
peter
2e161c5e9e * nf_internal flag for internal inserted typeconvs. This will
supress the generation of warning/hints
2004-11-02 12:55:16 +00:00