Commit Graph

33455 Commits

Author SHA1 Message Date
paul
749075a851 compiler: ignore case when check type parameters for identity
git-svn-id: trunk@16710 -
2011-01-05 18:27:05 +00:00
paul
0d6b62d293 compiler: allow generic inline specialization for delphi mode (like TFoo<Integer>.Create)
git-svn-id: trunk@16709 -
2011-01-05 18:12:44 +00:00
paul
d55a141d70 compiler: allow generics as class parents + fixed test
git-svn-id: trunk@16708 -
2011-01-05 05:03:21 +00:00
paul
bd64575add compiler: require generic name with type parameters for the method class prefix (like TGenericClass<T>.MethodName instead of TGenericClass.MethodName) in delphi mode
git-svn-id: trunk@16707 -
2011-01-05 04:35:56 +00:00
paul
fa41b6ffe3 compiler: allow generic classes to derive from generic classes and generic interfaces
- change id_type to single_type in readImplementedInterfacesAndProtocols to allow use of interface specializations inside class parent block
  - change single_type boolean arguments to set, add stoParseClassParent option to that set
  - move parse_generic variable assignment from parse_object_members to outer routine to setup it before parsing class parents
  - return paticular generic in generate_specialization instead of undefineddef to pass class/interface checks inside parent class block
  - add test for delphi mode
  - modify tw11431 to be syntatically correct

git-svn-id: trunk@16706 -
2011-01-04 18:20:40 +00:00
paul
4cfcc7ae7b compiler: implement delphi generic syntax for delphi mode
git-svn-id: trunk@16705 -
2011-01-04 11:06:29 +00:00
marco
a7c1e0f134 * ptypes updates from Jasper Lievens.
git-svn-id: trunk@16704 -
2011-01-04 09:33:55 +00:00
marco
ab744932b2 * errnostr by Jasper Lievens.
git-svn-id: trunk@16703 -
2011-01-04 09:14:03 +00:00
marco
56ca6b2db3 * small fix from Jasper Lievens.
git-svn-id: trunk@16702 -
2011-01-04 08:31:39 +00:00
Tomas Hajny
d2262b1a41 * avoid warning during compilation
git-svn-id: trunk@16701 -
2011-01-03 23:21:15 +00:00
Tomas Hajny
f0084393de + support for passing of options via environment variable added
git-svn-id: trunk@16700 -
2011-01-03 23:19:43 +00:00
Tomas Hajny
c12b695eb2 * added comment about planned support for passing of options via environment variable
git-svn-id: trunk@16699 -
2011-01-03 22:41:01 +00:00
Tomas Hajny
cbf2e4fc96 + rmwait building now included for os2, emx, go32v2 and windows targets; it should work on Unix targets too but no support for handling of Unix permissions required for proper working of --force is implemented yet
git-svn-id: trunk@16698 -
2011-01-03 22:29:52 +00:00
Tomas Hajny
0449c62dff + proper Makefile for rmwait added
git-svn-id: trunk@16697 -
2011-01-03 22:24:41 +00:00
Tomas Hajny
c59fc868e6 + have fpmc built for os2 and emx targets too
git-svn-id: trunk@16696 -
2011-01-03 22:17:10 +00:00
Tomas Hajny
dc21a0d721 * old make versions require a separator after colon in rule definitions
git-svn-id: trunk@16695 -
2011-01-03 22:13:33 +00:00
paul
e69de6110b rtl: add mkOperatorOverload to TMethodKind enum
git-svn-id: trunk@16694 -
2011-01-03 16:10:36 +00:00
pierre
f4597459b5 * Correct keybrd2 => keyboard2
git-svn-id: trunk@16693 -
2011-01-03 13:31:27 +00:00
Jonas Maebe
6fe0084caa * fixed result of NSObject(Protocol).hash: cuint -> NSUInteger (fixes 64 bit
compilation of cocoain)

git-svn-id: trunk@16692 -
2011-01-03 12:14:12 +00:00
Tomas Hajny
f5d9ab3038 * fixes for OS/2 threading support by Stefan Zigulec
git-svn-id: trunk@16691 -
2011-01-02 23:08:15 +00:00
marco
efabb72e71 * grapviz output for fpclasschart, mantis 18201
git-svn-id: trunk@16690 -
2011-01-02 21:09:30 +00:00
Jonas Maebe
5fc94a5076 * don't look for helper executables (assembler, linker, resource compiler,
wpo helpers) in the current directory

git-svn-id: trunk@16689 -
2011-01-02 20:25:41 +00:00
paul
dd921ffc9d utils: fix ppudump:
- show array symtable
  - support unicodestring
  - don't read "Last VTable idx" field in case of interface - this entry is not stored in ppu

git-svn-id: trunk@16688 -
2011-01-02 19:08:35 +00:00
marco
e896d94650 * fix for 18366, maximum_processors for 64-bit
git-svn-id: trunk@16687 -
2011-01-02 18:50:29 +00:00
paul
7c33505916 compiler: don't create enum defs for specializations declarations. Enums are stored in the unit symtables and generic declarations already add them there. Therefore specializations should search for enum defs declared by generics and use them instead of own.
git-svn-id: trunk@16686 -
2011-01-02 17:41:51 +00:00
Jonas Maebe
360d102ea4 * fixed some comments after r16684
git-svn-id: trunk@16685 -
2011-01-02 15:31:41 +00:00
Jonas Maebe
3ca3276400 * changed syntax of external objcclasses (see wiki/FPC_PasCocoa). Another
change is that it is now also allowed to specify an external name for
    formal external class definitions, but if they are later mixed with
    regular class definitions the external names have to match.
   o because the "external" status of methods is now set while parsing the
     class rather than afterwards, some procdir compatibility checks had to
     be inlined because they only have to be performed for 
  * also adapted the syntax for external cppclasses in the same way
  * fixed return type of NSObject.retainCount and NSObject.hash
    (NSUInteger instead of cint)
  * moved "patches" directory from cocoaint/src to cocoaint/utils/cocoa-skel
    so they are used by the conversion script when re-parsing the headers
  * updated Objective-C header parser script to
   o use the new external class syntax
   o not write inheritance information for root classes (NSObject, NSProxy)
   o use internal translation tables for some conflicting method names that
    are named specially in objcbase.pp
   and updated parsed headers
  * fixed rtl/inc/objcbase.pp and tests to conform to the new external class
    syntax

git-svn-id: trunk@16684 -
2011-01-02 14:50:46 +00:00
joost
4bd0f6db7a * Dwarf: Hide the implicit pointer from a function-parameter which is passed
by reference, and dereference the (hidden) pointer in the DW_AT_location
   block. This solves problems with function parameters defined as 'var'

git-svn-id: trunk@16683 -
2011-01-02 14:49:20 +00:00
paul
79813da090 compiler: don't allow record case with parameterized members
git-svn-id: trunk@16682 -
2011-01-02 14:01:09 +00:00
paul
55a0fefb1f compiler: implement generic array type:
- add tarraysymtable to store generic type symbols
  - process generic and specialize declarations similar to generic records and classes
  - fix insert_generic_parameter_types to use def passed in argument instead of current_structdef because generic array type can't be assigned to the current_structdef variable
  - increase ppu version because of arraydef changes
  - tests

git-svn-id: trunk@16681 -
2011-01-02 13:16:17 +00:00
paul
3ceee496d6 tests: fail test tw9509: disable type section in generic interfaces
git-svn-id: trunk@16680 -
2011-01-02 10:51:51 +00:00
paul
906ca89f4e compiler:
- allow pointermath for pchar, pwidechar, array[] of char and array[] of widechar without pointermath directive, 
  - don't check tpointerdef().has_pointer_math if this is not a tpointerdef

This fixes testsuite regression (tbs/tb0439.pp)

git-svn-id: trunk@16679 -
2011-01-02 04:35:05 +00:00
paul
7dd6cf07b4 compiler: comment TSymTableType entries + formatting
git-svn-id: trunk@16675 -
2011-01-01 16:59:33 +00:00
joost
a7cea8606f * Dwarf3: Classes are not encoded as a pointer to a class-structure, but
as a class-structure directly. Make sure that in this case:
     - The size is the size of the structure, not the size of a pointer
     - The (hidden) pointer is dereferenced
     - The class is marked as unallocated when the (hidden) pointer is nil

git-svn-id: trunk@16674 -
2010-12-31 17:45:58 +00:00
marco
dbb2a44286 * tconnectevent added to comobj
git-svn-id: trunk@16673 -
2010-12-31 15:50:19 +00:00
paul
fc33a2542b formatting
git-svn-id: trunk@16672 -
2010-12-31 05:46:44 +00:00
paul
e8502b8ec2 compiler: make current_genericdef, current_specializedef tstoreddef instead of tabstractrecorddef to implement generic arrays
git-svn-id: trunk@16671 -
2010-12-31 04:39:16 +00:00
paul
52667b6822 compiler: implement generics for records based on generic objects implementation + 1 test
git-svn-id: trunk@16670 -
2010-12-31 03:43:16 +00:00
paul
101f545ad0 compiler: don't allow generic object types (interfaces,dispinterfaces,objclasses,...) to have type,var,const sections if regular object types don't have them. currently only objects, classes and records are allowed to have nested type,var,const sections.
git-svn-id: trunk@16669 -
2010-12-31 02:31:51 +00:00
paul
b7f1ea0a93 compiler: remove unneeded check that def is objectdef when we have another check that object has vmt. records don't have vmt so we can leave only one check there
git-svn-id: trunk@16668 -
2010-12-31 02:26:41 +00:00
paul
89dc742de2 compiler: mark operator overloads as operators in rtti (although classes don't have operator overloads now)
git-svn-id: trunk@16667 -
2010-12-31 02:24:22 +00:00
Jonas Maebe
482a244f30 * version 2.13 of the parser, by Ryan Joseph: mainly restructuring and
cleanup

git-svn-id: trunk@16666 -
2010-12-30 23:28:02 +00:00
sergei
15e1abddf7 * Windows RTL: Simplify SysUtils.GetLocalTime(). TSystemTime type for these targets matches one defined in Windows unit, so WinAPI function result can be used directly. Resolves #18346.
git-svn-id: trunk@16665 -
2010-12-30 20:40:47 +00:00
Jonas Maebe
2222f2c44b * renamed is_class_or_interface_or_dispinterface_or_objc() into
is_implicit_pointer_object_type() to better indicate the purpose of
    that routine, and to avoid having to change its name every time
    a new object type with this property is added

git-svn-id: trunk@16664 -
2010-12-30 15:19:54 +00:00
Jonas Maebe
e8871f0885 * fixed and simplified tcgaddnode.second_addsmallset: don't modify
right.register for subn, because it may be constant

git-svn-id: trunk@16663 -
2010-12-30 14:55:57 +00:00
pierre
14a10ad6cb + Add $rbp FrameName for x86_64 CPU
git-svn-id: trunk@16662 -
2010-12-30 14:53:57 +00:00
paul
b437f85984 compiler: forgotten unit in r16660
git-svn-id: trunk@16661 -
2010-12-30 08:07:05 +00:00
paul
2af416e145 compiler: move current_objectdef variable to implementation of pdecobj and use explicit type conversion to tobjectdef in other places where current_objectdef is needed
git-svn-id: trunk@16660 -
2010-12-30 07:40:31 +00:00
paul
ee78cf0f06 compiler: use current_structdef in more places where current_objectdef was used, change type of current_genericdef and current_specializedef to tabstractrecorddef for future use with generic records
git-svn-id: trunk@16659 -
2010-12-30 07:33:57 +00:00
paul
dc5f5c3f63 compiler: use current_structdef instead of current_objectdef in more places
git-svn-id: trunk@16658 -
2010-12-30 06:46:06 +00:00