Dimitar Dobrev
8c394afd86
Simplified a type map in the tests.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
3917ca2584
Fixed renaming when items of an enum only differ by case.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
92da301135
Fixed the generation when a secondary base is used in more than one unit.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Joao Matos
2d57c787c6
Fixed generation support for pointers to enums in C#.
...
Fixes https://github.com/mono/CppSharp/issues/1093 .
7 years ago
Joao Matos
2a53e079aa
Fixed broken class instance check in FunctionToInstanceMethodPass.
...
Fixes https://github.com/mono/CppSharp/issues/1081 .
7 years ago
Matthew Albrecht
f8ccbb80c0
Added parameter index to managed marshal variables
7 years ago
Dimitar Dobrev
9ef1967955
Changed the generated C# for const references to primitives as just primitives.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
João Matos
74d753ae7f
Remove Linux test exclusion ( #1049 )
7 years ago
TheLastRar
430bbdb257
Evaluate expressions for enums generated using GenerateEnumFromMacros ( #1048 )
...
* Evaluate expressions when generating enum from macros
ExpressionEvaluator taken from https://github.com/codingseb/ExpressionEvaluator
* Set namespace for enums generated from macros.
* Add Tests
8 years ago
Rokas Kupstys
d8b53721ef
Fix for #1043 ( #1044 )
...
Field property getter returns non-value types by reference instead of by copy.
Fixes #1043
* Minor code clarity cleanup in GenerateFieldSetter. No behavior changed.
* Fix incorrect code generated in some cases.
* Test for fields getters returning references.
8 years ago
Dimitar Dobrev
67b241d95b
Added support for 16-bit wide characters (char16_t).
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
10c8211a7c
Fixed the generated C# when a template interface specialised with another specialisation returns a template parameter.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
ae9eede6f1
Fixed a crash when a constructor takes a template or specialisation.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
6dec97fd99
Fixed the generated C# for public fields with type a dependent pointer.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
4b310875d3
Enabled classes having specializations for secondary bases to call their extensions.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
a119bdb3f0
Fixed the generated C# for subclasses of specialisations used as secondary bases.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
cb6d2aee23
Fixed the generated C# when a template specialization with extensions is used for a secondary base.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
52c754c4de
Extended the multiple inheritance to work for templates.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
1e6c881bdc
Fixed a regression causing public fields of type specialization to be ignored.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
51c0f37aa3
Fixed the generated C# for templates with optional arguments.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
db3e04cca0
Represented "void" with "object" for template arguments in the generated C#.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
1a1308ad8a
Fixed the generated C# for public fields with type a dependent function pointer.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
c264690e90
Fixed the generated C# when a constructor has a default parameter with type an external specialisation.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
84f145b3e9
Fixed the generated C# when a function uses an external specialisation.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
fbd76adcb9
Fixed the generated C# when a base class is an external specialisation.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
a1327b4402
Fixed the generated C# for indexers with dependent keys.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
0ea147b1e3
Fixed the generated C# for templated indexers specialised with enums.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
8d0db5d341
Reverted a simplification because it caused a regression.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
10607164ed
Fixed the generated C# when a template returns a specialisation with itself as a type arg.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
fceb204a98
Fixed the generated C# for members of types nested in templates.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Rokas Kupstys
4e735b5b61
Test for consistent struct/class keywords.
...
Tests for cases where class name matches translation unit name.
Tests for cases where global constants/functions from different translation units would end up in the value type.
8 years ago
Dimitar Dobrev
e75e96bf72
Removed a duplicate explicit instantiation from the tests.
...
This fixes our CI on Unix.
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
caacaa841f
Worked around duplication of types nested in templates and forwarded.
...
Since all template specialisations are incomplete by default, so are classes nested in them. When such classes are also forwarded, there are two incomplete declarations with the same name and in the same scope. Our parser searches by name and completion and it can therefore not make a difference between the two. Consequently, it always returns the first type it finds even if it isn't the right one. When clang::Sema later completes the specialisations, it completes the nested types too which leads to two identical complete types in the same scope.
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
8cc67420d5
Fixed a crash when passing null as an std::string on Unix. ( #1012 )
...
Fixed a crash when passing null as an std::string on Unix
8 years ago
Dimitar Dobrev
e8e100be7b
Fixed the generated C# when a constructor takes a specialisation.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
4eb8ee83da
Fixed the generated C# for templates with fields other templates not used anywhere else.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
a913a74138
Fixed the generated C# when using std::map.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
4bfece6ab9
Fixed the generated C# for specialisations with an ignored specialisation as an arg.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
853e82f095
Fixed the generated C# for specialisations only used as type arguments.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
d996d8a4d0
Removed extensions for internal template specialisations.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
35902635ff
Fixed the parsing of an undeclared template specialisation with an extension method.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
faf0fbb656
Included template specialisations only used as returned types.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Mikulas Florek
04a1591e84
Fixed the generated C# for fixed arrays of Booleans.
...
fixes #1004
* mend
Fixed the generated C# for fixed arrays of Booleans
8 years ago
Dimitar Dobrev
10748cba2e
Fixed the generated C# when a type nested in a template is forwarded.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
9c2f62c3eb
Fixed a crash when parsing unnamed declarations in name-spaces.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
291da4ece3
ed time and memory during generation by skipping methods of most STD classes.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
efbe7cd3e4
Fixed the generated C# for a fixed array of pointers.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
8958217314
Sped the test run up by moving the test for ignored system types.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
b5c17d98bd
Verified that unused STD types are removed.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
ae6a37359a
Removed unused STD enumerations from generation.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago