Commit Graph

5457 Commits

Author SHA1 Message Date
Jonas Maebe
3f5e95791b * use iosxwstr instead of cwstring on Darwin (for iOS 7+ testing)
git-svn-id: trunk@29829 -
2015-02-23 22:48:15 +00:00
florian
c46cbd3b1a + test for an already fixed report (#14347), added to avoid that it pops up again
git-svn-id: trunk@29793 -
2015-02-22 20:33:01 +00:00
florian
cab98a58d0 + parameters of nested procedure variable parameters are taken into account during name mangling, resolves #27515
* de-duplicated parameter name mangling code

git-svn-id: trunk@29791 -
2015-02-22 09:16:20 +00:00
svenbarth
5a344ee263 Rework the way how "specialize" is handled. Instead of initializing the specialization of a full type declaration (including unit name and parent types) it is now considered part of the specialized type itself. This means that for example the following code:
type
  TTestLongInt = specialize SomeOtherUnit.TTest<LongInt>;

will now have to read as

type
  TTestLongInt = SomeOtherUnit.specialize TTest<LongInt>;

While this is not backwards compatible this situation should arise seldomly enough and the benefits especially in context with generic functions/procedures/methods outway the drawbacks.

pbase.pas:
  * try_consume_unitsym: add a allow_specialize parameter that allows to parse "specialize" in front of a non-unit symbol; whether it was a specialization or not is reported using a new is_specialize parameter
  + add a new overload try_consume_unitsym_no_specialize that calls try_consume_unit sym with allow_specialize=false and a dummy is_specialize parameter
  * switch calls to try_consume_unitsym to try_consume_unitsym_no_specialize
pstatmnt.pas, try_statement:
  * switch call to try_consume_unitsym to try_consume_unitsym_no_specialize
  * adjust call to parse_nested_types
ptype.pas:
  + extend id_type with the possibility to disallow unit symbols (needed if a specialize was already parsed) and to report whether a specialize was parsed
  + extend parse_nested_types with the possibility to tell it whether specializations are allowed
  * have parse_nested_types specialize generic defs if one is encountered and local type defs are allowed
  * id_type: only allow "unitsym.specialize sym" or "specialize sym", but not "specialize unitsym.sym"
  * single_type: correctly handle specializations with "specialize" keyword
  * read_named_type.expr_type: there is no longer a need to check for "specialize" keyword
pexpr.pas:
  + new function handle_specialize_inline_specialization which tries to specialize a type symbol
  * handle_factor_typenode: handle specializations after a point that follows a record or object (why isn't this part of postfixoperators anyway? O.o)
  * postfixoperators: handle "specialize" after records and objectdefs
  * factor_read_id: handle "specialize" in front of an identifier (and after unit symbols)

+ added tests
* adjusted test webtbs/tw16090.pp

git-svn-id: trunk@29768 -
2015-02-20 16:23:40 +00:00
pierre
2095698a17 Use FPC_LOCALS_ARE_STACK_REG_RELATIVE macro to fix test for mips/mipsel
git-svn-id: trunk@29762 -
2015-02-19 16:56:02 +00:00
Tomas Hajny
7049e40668 * character ASCII 127 should not be treated as invalid result of Unicode to ansistring conversion because it is used as replacement character for characters missing in the target codepage by the native OS/2 Unicode support routines
git-svn-id: trunk@29706 -
2015-02-15 14:31:36 +00:00
Tomas Hajny
46bfe5c1dd * set ShortDateFormat explicitly so that StrToDate behaviour can be tested easily regardless of current locale
git-svn-id: trunk@29703 -
2015-02-15 11:28:17 +00:00
Tomas Hajny
41312d44b4 * set DecimalSeparator explicitly so that Format output can be tested easily regardless of current locale
git-svn-id: trunk@29701 -
2015-02-15 11:14:55 +00:00
Tomas Hajny
e1b37dcc46 * the test made compilable also on other platforms than only Unix and Windows
git-svn-id: trunk@29699 -
2015-02-15 01:34:47 +00:00
Tomas Hajny
90aeabb439 * skip this test under OS/2, because it expects that replacement used for characters not supported in the current codepage must match between compile time ('?' used by FPC) and run-time (ASCII 127 used by OS/2 native Unicode routines)
git-svn-id: trunk@29698 -
2015-02-15 01:31:27 +00:00
Tomas Hajny
fbb6776085 * this test results in a SIGSEGV under OS/2, but I consider it a correct behaviour if a nil pointer for passing a nil as a buffer to BlockWrite
git-svn-id: trunk@29697 -
2015-02-15 01:04:32 +00:00
Tomas Hajny
d2ae1f0ab2 * skip emx too
git-svn-id: trunk@29696 -
2015-02-15 01:01:56 +00:00
Tomas Hajny
60c5f29b5b * add path setting for some previously missing platforms (OS/2, MSDOS)
git-svn-id: trunk@29695 -
2015-02-14 20:46:58 +00:00
florian
3ed1a75fcd * write ok on exit for easier testing
git-svn-id: trunk@29693 -
2015-02-14 17:39:32 +00:00
Tomas Hajny
2e2ca8684d * add resolution of DLL name under OS/2
git-svn-id: trunk@29689 -
2015-02-13 22:36:49 +00:00
Tomas Hajny
95c0092a54 * skip test if CPU does not support SSE2 (similarly to test/tshuffle1.pp)
git-svn-id: trunk@29688 -
2015-02-13 22:24:17 +00:00
svenbarth
a7085ea34e Added test for Mantis #25044 which has been fixed in revision 29537.
git-svn-id: trunk@29687 -
2015-02-13 17:02:07 +00:00
Jonas Maebe
071282b286 * add methods of objcprotocols to the list of visible "helper" methods when
loading them from ppu (like was already done when they were initially
    compiler), so they can be called via the "id" type even if no classes are
    in scope that implement them

git-svn-id: trunk@29686 -
2015-02-13 15:43:34 +00:00
svenbarth
04534d5dcf Fix for Mantis #27424.
pgenutil.pas:
  * parse_generic_parameters: a ';' terminates a parameter group, so correctly adjust firstidx in that case

+ added test

git-svn-id: trunk@29685 -
2015-02-13 13:50:47 +00:00
Tomas Hajny
cd166e6ff6 * modified according to outcomes of discussion with Jonas
git-svn-id: trunk@29677 -
2015-02-12 23:16:13 +00:00
Tomas Hajny
bd719052fa * test updated according to results of discussion with Jonas to work properly also on platforms not using UTF-8 as their default system codepage (and be safe to ignore characters possibly unsupported with current system codepage)
git-svn-id: trunk@29676 -
2015-02-12 23:02:20 +00:00
Tomas Hajny
08a3c45aa3 * test fixed because the original version was wrong (as confirmed by Jonas)
git-svn-id: trunk@29675 -
2015-02-12 17:48:00 +00:00
Tomas Hajny
da21fe94fa * this test can never work correctly on operating systems not providing Unicode support at filesystem API level unless the current codepage happens to support all the characters used within the test (which is unlikely at least)
git-svn-id: trunk@29674 -
2015-02-12 00:55:18 +00:00
pierre
a02344e978 Restore default for OS and CPU to All ID and increase max size of comboBox to 100
git-svn-id: trunk@29672 -
2015-02-11 21:51:53 +00:00
Tomas Hajny
8c20ff7f91 * fix for AllowOneTrailingSeparator and AllowMultipleTrailingSeparators checks and tests using these variables according to the passed parameters
git-svn-id: trunk@29671 -
2015-02-11 21:22:01 +00:00
pierre
82f751d51a Handle one trailing separator separately from multiple
git-svn-id: trunk@29670 -
2015-02-11 10:58:04 +00:00
Tomas Hajny
2cf9d18b14 * invalid DosError display improved
git-svn-id: trunk@29665 -
2015-02-10 16:43:15 +00:00
Tomas Hajny
3caf47d756 * display the wrongly obtained invalid DosError value too
git-svn-id: trunk@29664 -
2015-02-10 16:40:06 +00:00
florian
932b68310e * do not warn about internally generated parameters, resolves #25914
git-svn-id: trunk@29636 -
2015-02-06 20:44:24 +00:00
Tomas Hajny
6e4dea39d3 * avoid use of single quotes in Makefile under OS/2
git-svn-id: trunk@29621 -
2015-02-04 01:24:05 +00:00
florian
42020c8bb8 * when passing a parameter by var/out, its address leaves the current scope so the compiler has to take care of this
* when getting rid of temps. of inline parameters, take care if somewhere an alias of the variable might exist, resolves #24796 and #26534

git-svn-id: trunk@29616 -
2015-02-03 21:05:39 +00:00
pierre
488024ea5c Fix for failures on FileNameCaseSensitive systems
git-svn-id: trunk@29609 -
2015-02-02 21:49:36 +00:00
florian
461821d1a5 * read array initializations in generic subroutines without fixed limits, resolves #25602
git-svn-id: trunk@29598 -
2015-02-01 17:09:00 +00:00
Jonas Maebe
5d4837329b * changed {$modeswitch blocks} to {$modeswitch cblocks} to avoid confusion
with the Pascal meaning of the term "block"

git-svn-id: trunk@29594 -
2015-02-01 15:50:06 +00:00
sergei
adeb8c93e9 * Set pi_do_call flag explicitly when procedure has a parameter or local var that require finalization. Normally it is set by implicit try..finally node, but this node is absent when compiling in {$implicitexceptions off} mode. This may cause internal errors in pass 2 if pi_do_call has not been set by other means.
Fixes IE when compiling Lazarus for MIPS target.
+ Test.

git-svn-id: trunk@29590 -
2015-01-31 13:33:36 +00:00
Jonas Maebe
ff25f5c923 * set DYLD_LIBRARY_PATH instead of LD_LIBRARY_PATH on Darwin
git-svn-id: trunk@29586 -
2015-01-30 19:31:28 +00:00
svenbarth
ba75fd62f0 Fix for Mantis #27348. Applied patch by Do-wan Kim plus comments for the reason.
symdef.pas:
  * tprocdef.defaultmangledname: add some kind of differentiator to the result def, so that x(integer;integer) and x(integer):integer generate different mangled names
  * make_mangledname: also use the returndef instead of a potentially uninitialized variable like was done for tprocdef.defaultmangledname and also add a prefix (so that the two are compatible)

+ added test

git-svn-id: trunk@29579 -
2015-01-30 13:49:25 +00:00
Tomas Hajny
caa749f6a0 * UTF-8 may not be the system codepage on OS/2 - skipped
git-svn-id: trunk@29566 -
2015-01-27 16:47:40 +00:00
Tomas Hajny
693a239842 * information about GCC version used for compiling the OS/2 object files added
git-svn-id: trunk@29565 -
2015-01-27 16:24:24 +00:00
pierre
84bb209ce8 Add some missing C compiler information found inside C objects
git-svn-id: trunk@29564 -
2015-01-27 13:48:44 +00:00
Tomas Hajny
5a03b52801 * compiled object files for OS/2
git-svn-id: trunk@29563 -
2015-01-27 09:20:55 +00:00
Tomas Hajny
d3ee7d4999 * there is no wchar.h included in EMX GCC port (but it is fortunately not needed for our testsuite)
git-svn-id: trunk@29562 -
2015-01-27 09:17:05 +00:00
pierre
ddee662665 Add i386 specific check that fpu stack is completely empty in CheckStack function
git-svn-id: trunk@29554 -
2015-01-26 13:13:55 +00:00
Tomas Hajny
5f0a671ddc * single quotes are not accepted under OS/2
git-svn-id: trunk@29541 -
2015-01-24 11:12:31 +00:00
svenbarth
943a094683 Fix for Mantis #27320.
symdef.pas, tprocdef:
  * defaultmangledname: don't use the potentially unassigned hp, but use - as intended - returndef if it is set (analog to the non-CRC part)

+ added test

git-svn-id: trunk@29537 -
2015-01-23 16:47:23 +00:00
pierre
9af030ba9e Add missing x86_64-solaris gcc compiled objects
git-svn-id: trunk@29536 -
2015-01-23 14:23:47 +00:00
pierre
16262bb10e Add missing i386-solaris gcc compiled objects
git-svn-id: trunk@29535 -
2015-01-23 14:18:18 +00:00
Tomas Hajny
150ead4546 * skipping wrAbandoned test unsupported on OS/2 similarly to MS Windows
git-svn-id: trunk@29528 -
2015-01-22 23:52:22 +00:00
Tomas Hajny
33856b9f7b * fix typo in message and deallocate all previously allocated memory
git-svn-id: trunk@29527 -
2015-01-22 23:49:04 +00:00
Tomas Hajny
054ada1191 * skip this test for os2 and emx targets because it tries to link in a resource file in MS Windows format (rather than the OS/2 format) which is not supported
git-svn-id: trunk@29523 -
2015-01-22 21:24:21 +00:00