Dimitar Dobrev
304d673bf7
Add a generic pointer to resolve ambiguity
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
6 years ago
Dimitar Dobrev
c75e9f6c5e
Fix a crash when a function pointer is a template arg
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
6 years ago
Dimitar Dobrev
d735f391b1
Fix the generated C# for fields of type function pointer
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
6 years ago
Dimitar Dobrev
d5380fe890
Fix the generated C# for const char*&
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
6 years ago
Dimitar Dobrev
6e78b4df15
Fix the generated C# when type arguments are mapped the same
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
6 years ago
Dimitar Dobrev
4dcbff3d62
Fix the generated C# for a case with 2 template args
...
When a template with 2 args and a method with a dependent pointer was specialized with const char*, there were methods with identical signatures generated for different specializations.
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
6 years ago
Joao Matos
02955f913d
Added statement visiting to IAstVisitor.
6 years ago
Joao Matos
0b825e1124
Changed more overloads in `CSharpSources` to be overridable.
6 years ago
Joao Matos
2a7f36fb2f
Extract C# base type printing in `CSharpSources.GetBaseClassTypeName`.
6 years ago
Joao Matos
863566ef43
Added `CSharpSources.IsReservedKeyword` static helper method.
6 years ago
Joao Matos
c1ab16b6a7
Changed `CCodeGenerator` reserved keyword checking helpers to be static.
6 years ago
Joao Matos
aa73692543
Obsolete managed expression class machinery.
6 years ago
Joao Matos
d773b4bc9f
Added `PrintModuleOutputNamespace` option to `CSharpTypePrinter`.
6 years ago
Joao Matos
1eb3b77d42
Fixed extraneous new lines when generating multi-line comments.
6 years ago
Joao Matos
86898121af
Added support for scope kinds in `CSharpTypePrinter`.
6 years ago
Joao Matos
850dcfaf67
Changed `CSharpTypePrinter.IntPtrType` to be a getter property.
6 years ago
Joao Matos
579df276e4
Add `ScopeKind` to base `TypePrinter`.
6 years ago
Joao Matos
f642cefe5f
Move `ITypePrinter` from `AST` to `Generator`.
6 years ago
Joao Matos
657f894bb2
Added `CCodeGenerator.GenerateClassBody` extension point.
6 years ago
Joao Matos
26a5525aa4
Added `CCodeGenerator.GenerateExtraClassSpecifiers` extension point.
6 years ago
Joao Matos
cc5539b69e
Added `CCodeGenerator.WriteInclude(string file, CInclude.IncludeKind kind)`.
6 years ago
Joao Matos
f2e18c1ffb
Skip ignored enum items in `CCodeGenerator.VisitEnumDecl`.
6 years ago
Joao Matos
1ef9bee970
Added reserved keywords checking helpers in `CCodeGenerator`.
6 years ago
Joao Matos
405f3ba92b
Only generate `unsafe` and `IDisposable` for bindings generation.
6 years ago
Joao Matos
d30909dfbd
Skip generation of ignored bases in `CSharpSources.GenerateClassSpecifier`.
6 years ago
Joao Matos
9a71598d52
Add constructor overload `CSharpSources(BindingContext context)`.
6 years ago
Joao Matos
e991a8d3d6
Skip generation of ignored enum items in `CodeGenerator`.
6 years ago
Joao Matos
6dfd16ba9b
Move `CppTypePrinter` to generators and inherit from `TypePrinter`.
6 years ago
Joao Matos
a0c5dc8349
Added a `CCodeGenerator` class and move `Include` class as `CInclude`.
6 years ago
Dimitar Dobrev
bc7f20a10a
Fixed the generated C# when an instance method has a parameter named "instance".
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
6 years ago
Dimitar Dobrev
5df67cd0c7
Fixed the generation for parameters of type void**.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
6 years ago
Dimitar Dobrev
d97016fe3c
Fixed the generated C# for indexers in templates specialized with void*.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
6 years ago
Dimitar Dobrev
cd32a449c8
Fixed the generated C# for template specializations of pointers.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
6 years ago
Dimitar Dobrev
6602841a3c
Fixed the generated C# for const void*& in parameters.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
6 years ago
Dimitar Dobrev
1ea19d5a1e
Made an exception serializable and removed another.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
5e0e19ea18
Fixed the generation of dependent virtual methods.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
a430d19870
Simplified the generation of virtual calls.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
f4673f5d7f
Extended the type maps for primitive strings to C++/CLI.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
a65f91949c
Handled int and long in maps to help resolve ambiguity.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
efa11ab745
Simplified type maps by unlinking them from declarations.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
a4913509eb
Added type maps for primitive strings (pointers to char).
...
const char*, const char16_t* and const wchar_t* in particular.
This enables comparison of types when resolving ambiguity.
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
41b22762a4
Fixed the marshalling of std::string with GCC 6+ on Linux.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
43bb2ee4bb
Added a type map for char.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
3b51325f0a
Deleted an unused member in type maps.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
e10fc01bff
Changed type maps to only return types - no strings.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
76d8182fe6
Simplified type maps by using static objects to disable as needed.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
760caf4d83
Simplified the logic for indentation by using numbers.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
b7d3d36ff1
Renamed members related to indentation for more clarity.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
d243780e67
Optimized the generation of C# by not splitting any strings.
...
Our indention of lines in blocks was inadequate so we used to split strings by new lines, indent each line and put it back together. Creation of new strings is incredibly slow so this bogged our code generation down. I have now fixed indention properly and we no longer need to split already written blocks to indent them.
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
34ad79529d
Optimized the generation of C# by avoiding splitting.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago