Salvage
b4f261ea38
Simplify `IsTemplateParameterType`
2 years ago
Salvage
28000a14b4
Fix #1251 three parameter equality operator
...
- Operators in generic classes do not attempt to generate as extension methods anymore
- Empty `...Extensions` classes are no longer generated
- `string` as a template argument is correctly cast
- `MarshalCharAsManagedChar` option also generates correct casts
- Suppress warning regarding returning struct field by ref
- Eliminate some tabs that snuck into the test C++ header
2 years ago
Joao Matos
17102021cc
Add Method.IsVolatile property.
...
Fixes https://github.com/mono/CppSharp/issues/1761
2 years ago
Joao Matos
9f3ce76261
Fixed debugging printing when type printing delegate is not initialized.
2 years ago
João Matos
bb31bd616b
Add type parameter to non-type template parameter decls. ( #1749 )
2 years ago
Trung Nguyen
add3aba684
CSharp: More default parameter fixes ( #1747 )
...
- Expression generation for `ConstructorReference` now also recursively
calls `VisitExpression` for the argument if only one argument is
detected. This allows correct overload generation for functions taking
a variable as the default parameter value.
- Default parameters of pointer-to-enumeration types are now correctly
generated similar to primitive types.
2 years ago
stachu99
9923d79617
CppSharp.AST.Declaration - fix return QualifiedOriginalName, QualifiedLogicalOriginalName ( #1740 )
...
Fixed properties getters of QualifiedOriginalName, QualifiedLogicalOriginalName and methods GetQualifiedName(), GatherNamespaces.
2 years ago
João Matos
4417dd987a
Code cleanups and improvements ( #1713 )
...
* Code cleanups.
* Run GetterSetterToPropertyPass for more generators.
* Fixed compile warning when compiling parser bindings.
* Cleanup driver code.
* Remove dead 32-bit code.
* Reduce verbosity when Options.Quiet is set.
* Remove test compile-time warnings.
* Move .NET tests to tests/dotnet.
* Remove unused AST viewer code and premake-qt submodule.
* Move tests2/ contents to tests/.
3 years ago
João Matos
9b06e7bc01
Add C++ WebAssembly ABI ( #1711 )
...
* Minor code refactorings.
* Fix debug assert issue with vtable methods.
* Add support for WebAssembly C++ ABI to parser and AST converter.
3 years ago
João Matos
db7949b263
Misc changes ( #1710 )
...
* Minor code refactoring for re-use.
* Add Class.FindVariable helper method.
* Upgrade to .NET 6.
3 years ago
josetr
c1b3a1e4d4
Fix HasDependentValueFieldInLayout stack overflow
3 years ago
josetr
efdec41f13
Add missing GenerateNativeToManagedFor checks
3 years ago
josetr
060afd53fc
Add partial `ref` param support
3 years ago
josetr
eb5031bf4c
Format files
3 years ago
Dimitar Dobrev
1acb23813d
Generate valid C# for independent specialisations with nested fields
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
f1915b3066
Generate valid C# for templates with external specializations only
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
c84a6c606e
Generate valid C# for independent external specializations
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
dddd5da0e6
Update LLVM to the latest version
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
5e328da9e7
Fix C# layouts for classes with nameless unions
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
2da9e49fe8
Instantiate specialized classes nested in templates
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
3aab30f572
Add built-in compilation of extra symbols
...
Fixes https://github.com/mono/CppSharp/issues/1456 and https://github.com/mono/CppSharp/issues/1253 .
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
f97ad43ce4
Generate valid C# for base types with public fields of const char*
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
15a55483ff
Extend finding of functions to also get overloads
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
c36145b29d
Bind default constructors with dependent pointers
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
7ead6b4574
Don't print tags for nameless and typedef classes
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
c6768bcac5
Fix C4099 (class as struct) in generated C++/CLI
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Dimitar Dobrev
8d8c67d3a4
Bind the tag kind (struct, class, enum) of a type
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
4 years ago
Joao Matos
4deb35e272
Maintain DeclarationsList integrity by clearing item offsets.
5 years ago
Joao Matos
5004d9eada
Rework core implementation of QuickJS generator.
...
This adds more accurate overloading, default arguments handling and
events.
5 years ago
Joao Matos
1e8db6020e
Add convenience constructor to ArrayType.
5 years ago
Joao Matos
50451ac897
Code cleanup.
5 years ago
Joao Matos
88fc5b9c36
Rewrite GenerateEnumFromMacros helper to also look into enum items.
5 years ago
Joao Matos
bcc6fd887d
Improve visiting options implementation in CodeGenerator.
5 years ago
Joao Matos
d6dd93d2f8
Minor code cleanups.
5 years ago
josetr
62e9119c63
Create a single nuget package that supports windows / linux / macos
5 years ago
Joao Matos
5cb683a199
Normalize visiting overloads to be virtual.
5 years ago
Joao Matos
a3a70ad0f5
Simplify TU.FileRelativeDirectory by using Path.GetDirectoryName.
5 years ago
Joao Matos
db08034d4b
Clean up some properties in TranslationUnit.cs with null coalescing operators.
5 years ago
Joao Matos
f18022b57e
Fix TU.FileRelativeDirectory to be more robust against some paths.
5 years ago
Joao Matos
bc22e1808e
Update Class.HasNonIgnoredBase to use the actual base class.
5 years ago
josetr
1926e69435
Only use premake for native projects and improve c# projects.
5 years ago
josetr
dbbcb6dbdf
Upgrade to .NET Core 3.1 and improve build system
5 years ago
Dimitar Dobrev
0e38947e07
Convert the visiting options to an enum
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
5 years ago
Joao Matos
d46bcd3dda
Implement Method.HasSameSignature for signature comparison.
5 years ago
Joao Matos
a85e94a3f2
Implement Method.ToString() to help with debugging.
5 years ago
Dimitar Dobrev
7bc0db7ae6
Don't wrap trivial constructors and destructors
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
5 years ago
Joao Matos
714fb7ecc4
Add per-declaration support for decl maps.
5 years ago
Joao Matos
5e74bc351f
Add TypeQualifiersMode to Type and implement in C++ type printer.
5 years ago
Joao Matos
6b53f5828a
Add new VisitQualifiedType overload to visitors.
5 years ago
Joao Matos
d47bce5700
Set include path as weell as file path when creating a new TU.
5 years ago