Dimitar Dobrev
19f3400cff
Extended the generation of implicit ctors.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
11 years ago
triton
684a9ff52b
Fixed wrapping of virtual overloaded operators.
...
References #389 .
11 years ago
Dimitar Dobrev
ca2b3a312e
Moved IsSynthetized from Method to Function.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
Conflicts:
src/AST/Method.cs
11 years ago
Dimitar Dobrev
f88c20aa94
Some refactoring in preparation for the default values of parameters.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
11 years ago
Tomi Valkeinen
7289a06b9e
Rename PrimitiveType Int32 and UInt32 to Int and UInt
...
As enum PrimitiveType is supposed to represent C++ types, having Int32
and UInt32 there is not correct.
This patch renames those values to Int and UInt.
This doesn't change the behavior, but makes it clearer that the types
for 'int' and 'unsigned int' are not necessarily 32 bits.
11 years ago
Tomi Valkeinen
4e185973e5
Normalize all the line endings
...
Normalized all the line endings with:
git rm --cached -r .
git reset --hard
git add .
git commit -m "Normalize all the line endings"
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@iki.fi>
11 years ago
Elias Holzer
0c260bd223
Improved support for indexed properties.
...
More types and types with different qualifiers are supported now - in both backends. See test cases for details.
11 years ago
Elias Holzer
474f82b513
Added support for explicit conversion operators and added new pass which will create implicit and explicit conversion operators out of single argument constructors.
...
Conflicts:
src/Generator/Passes/CheckAmbiguousFunctions.cs
src/Generator/Passes/CheckOperatorsOverloads.cs
11 years ago
marcos henrich
7125109e3f
Deprecated ExplicityIgnored use ExplicitlyIgnore(). Getting ExplicityIgnored and setting ExplicityIgnored to false don't make much sense anymore.
...
Conflicts:
src/Generator/Passes/CheckOperatorsOverloads.cs
11 years ago
marcos henrich
3f96bdbfe3
Replaced declaration IgnoreFlags by GenerationKind. Added methods IsInternal and IsDeclared to declaration. Replaced IsGenerated = true by GeneratioKind = GeneratioKind.Internal. Deprecated Ignore, replace Ignore set by ExplicityIgnored, replace Ignore get by IsGenerated, IsInternal or IsDeclared.
...
Conflicts:
src/Generator/Passes/CheckOperatorsOverloads.cs
11 years ago
Elias Holzer
f091c6662a
CLI generator will use the pointee type for indexed properties which have a setter.
11 years ago
Elias Holzer
e6cb543c36
Fixed overloading of an indexed properties by removing the hard coded "int index" part.
11 years ago
triton
e95a2929a8
Fixed handling of property indexers in the CLI generator.
11 years ago
Elias Holzer
a115bd9a51
Overload comparison operators only if their native counterpart return bool.
11 years ago
Øystein Krog
d3e963ff19
Move helper methods in Type out from class and into extension class TypeExtensions
11 years ago
triton
8d9e866009
Added support for clearing declarations between visits and fixed some passes that need it.
12 years ago
triton
5817f58cd4
Fixed all passes for the new ASTVisitor behavior.
...
Added ignore and method checking code to the MoveFunctionToClass pass.
12 years ago
Dimitar Dobrev
c0ed93cd5e
Prevented postfix and dereference operators from being wrapped as such because C# does not support them.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
d2e7e99bc3
Fixed the issue about member pointers not pointing to a function. Turns out this is some "pointer to a data member" (?!) that is of little use so just ignore it.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
95687a22b6
Added two hacks: one for operators in general, one for a parser issue.
...
1. Visit the class as a declaration context when checking operator overloads - otherwise operators in nested types are not checked; this is, however, not the proper solution because all visiting of classes should be refactored so that this and any other methods are always called as necessary;
2. A single conversion operator in Qt misleads the parser into resolving a function pointer while it is (most probably) not; this caused a subsequent crash.
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
88d5192684
Wrapped conversion (cast) operators.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
6f3224ca60
Changed writable indexers of primitive types to use the types themselves instead of pointers.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
b82aebab3a
Added support for writing using indexers.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
083dc3a9f8
Improved the generation of indexers by removing const overloads of []. NOTE: did that by removing the method type check in the pass for ambiguous overloads.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
54c93f4d91
Added support for read-only [] operators.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
453dc26964
Fixed the generation of complement operators.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
2848ee7453
Fixed a regression causing a run-time crash with moved operators.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
triton
e0a2624370
Removed unused using.
12 years ago
triton
458ef0ce34
Emit a debug info instead of an error for "invalid" operator overloads.
12 years ago
triton
36d520562e
Use references instead of pointers when creating new operator overloads methods.
12 years ago
triton
17fdab07cb
Only add missing operator overloads in C# generator.
12 years ago
triton
13c5357e3f
Use references instead of pointers when creating new operator overloads methods.
12 years ago
triton
f704ca3a05
Only add missing operator overloads in C# generator.
12 years ago
triton
c8abdeb192
Cleaned up operator overload helpers.
12 years ago
Dimitar Dobrev
5208fafef7
Moved GeneratedIdentifier to the base Generator so that the former is available to all back-ends.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
2063aa2216
Fixed the filling of missing operators to account for operator overloads.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
90732c6ca7
Corrected the overloading of << and >> by making sure the second parameter is implicitly convertible to int.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
marcos henrich
0cf8c03aa3
PassBuilder is now generic. Driver Passes is now called TranslationUnitPasses. Added to driver GeneratorOutputPasses. Removed most of the PassBuilder Extensions.
12 years ago
triton
68ddfbdd6f
Move the AST project to the CppSharp.AST namespace.
12 years ago
triton
f26018db87
Fixed CheckOperatorsOverloads pass to work correctly for non C#-supported operator overloads.
12 years ago
triton
b0d2757238
Fixed the CheckOperatorsOverloads pass to be more robust when handling declarations.
12 years ago
triton
46d9978401
Class helper methods now return proper lazy IEnumerable<> instead of converting right away to lists.
12 years ago
triton
cc8f7cd1db
Renamed Cxxi references to CppSharp.
12 years ago
triton
f8eeacab5d
Check for missing operator overload parameters for all operator overloads.
12 years ago
triton
af8b863286
Extract the operator checking code into its own method.
12 years ago
triton
a14338a8c9
Added much improved support for operator overloading in the C# backend.
12 years ago