David Maas

Results 121 issues of David Maas

Right now arrays of function pointers are emitted as normal non-function pointer arrays, which emits the following invalid methods: ```csharp public Span AsSpan() => new Span(Element0Pointer, 8); public ConstantArrayEnumerator GetEnumerator()...

Bug
Language-C#
Concept-OutputUsability
EdgeCase
Workaround

For types without constructors, the C++ compiler may initialize the vtable pointer wherever the type is initialized. This was encountered with PxDefaultAllocator. Here's a simple example: ([Godbolt](https://godbolt.org/z/P8948Y)) ```cpp class AbstractBase...

Concept-CppFeatures
Area-OutputGeneration
Concept-OutputUsability
Concept-InlineExpectation
Blocks-PhysX

I meant to do this when I added the ability to check if a macro has a value, but apparently I forgot.

Concept-ApiClarity
RelativelySmall

If you're trying to use Biohazrd on a platform besides Windows x64 or Linux x64, you need to install an additional ClangSharp.Pathogen runtime support package for your platform. Biohazrd automatically...

Concept-CrossPlatform
RelativelySmall

Right now if Biohazrd fails to emit a type, it will emit it as int in order to make sure the C# code still compiles: ```csharp [FieldOffset(0)] public /* Failed...

Area-OutputGeneration
Concept-OutputFriendliness

IE: ```c const int SomeConst = 100; ``` One consideration to be made for these types: I believe C++ guarantees that `&SomeConst` is the same across all translation units. (If...

Concept-CppFeatures
Area-Translation

At some point Clang cursor detail dumping broke, probably when we upgraded from Clang 10. Attempting to use `ClangSharpInfoDumper` or enabling dumping in the C# output via `CSharpGenerationOptions.DumpClangInfo` will result...

Bug
External

Not the end of the world since most C libraries tolerate being built in C++ mode, but we should handle this situation.

Bug
Area-Transformation

In C# it is not possible to get the unmanaged function pointer behind a `DllImport`. (The function pointer type of a `DllImport` is managed because it might be a marshal...

Area-Transformation
Area-OutputGeneration
Language-C#
Concept-OutputFriendliness
Blocks-PhysX