Jelle
7105da02fe
Bootstrap code changes ( #1914 )
...
* Ignore 'BootstrapPatch' folder
Just in case
* Split into files
* Abstract some `ASTConverterCodeGenerator` code
* Code cleanup
* Abstraction improvements
5 months ago
Jelle
b8714867b6
Fix/bootstrap update ( #1904 )
...
* Fix warning
* Code cleanup
* Add missing native project launch settings
* Fix bootstrap generator
Update bootstrap / parser gen lang version
* Fix bug in `std::optional` mapping
* Fix crash with null template
* Use arm64 headers if available
* Support some `std::optional/vector` methods
* Add optional for csharp
* Template type alias cast fix
* Update generated bootstrap/parser bindings
* Temp fix for build errors in bindings
* Fix `IgnoreSystemDeclsPass` not visiting all declared overrides
* Drop optional support for now
I'm struck on `std::optional:<>:operator=(Ty&&)`, would need to add some code that handles by creating a function for default template arguments but this PR has already become way too large
* Add formatting settings
* Format all files
5 months ago
Jelle
fe7afc3b05
Fix some template declarations not setting namespace ( #1913 )
...
* Fix some template declarations not setting namespace
* throw on unsupported arch/platform
* Update bindings
5 months ago
Jelle
f0b44b4421
Code cleanup and some optimizations ( #1911 )
...
* Code cleanup
* Run symbol conversion in parallel
* Fix build error in p/invoke move
* Fix debug compile
* Address review comments
6 months ago
Jelle
e4979d185d
Fix `DEBUG` not being defined in C# `DebugOpt` configuration ( #1908 )
6 months ago
Jelle
80bfc78fa6
Fix crash on auto return types ( #1898 )
...
Not sure if this is resolved properly
6 months ago
Joao Matos
b5ab95e11d
Update iOS64 ABI name to the more accurate AppleARM64.
2 years ago
Joao Matos
d1307a532f
Add support for AArch64 C++ ABI.
2 years ago
deadlocklogic
9071cd2a59
Implement ClassTemplatePartialSpecialization::Parameters ( #1809 )
...
* Implement ClassTemplatePartialSpecialization::Parameters
* Template.cs: Implement ClassTemplatePartialSpecialization.Parameters
* GeneratorKind: fix bug introduced while migrating from enum to class
* Implement native ClassTemplatePartialSpecialization.Parameters + ASTConverter
* regenerated bindings (#1813 )
* regenerated bindings
* regenerated bindings after rebase
* Directory.Build.props: support C# 10.0
* Implement native ClassTemplatePartialSpecialization.Parameters + ASTConverter
* Regenerated bindings
* TestAST.cs: add TestASTClassTemplatePartialSpecialization
2 years ago
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.
4 years ago
Joao Matos
5004d9eada
Rework core implementation of QuickJS generator.
...
This adds more accurate overloading, default arguments handling and
events.
4 years ago
Joao Matos
1e8db6020e
Add convenience constructor to ArrayType.
4 years ago
Joao Matos
50451ac897
Code cleanup.
4 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