Skip to content

ArgumentException in ClangSharp generator dotnet tool #413

@kostya9

Description

@kostya9

Looks like the exception is similiar to #403

Version: 15.0.2

STR:

  1. clone https://github.com/kostya9/NetObsBindings
  2. Run ./build.ps1 (it uses clangsharp generator dotnet tool)
  3. Observe exception
Unhandled exception: System.ArgumentException: Stream was not writable.
   at System.IO.StreamWriter..ctor(Stream stream, Encoding encoding, Int32 bufferSize, Boolean leaveOpen)
   at ClangSharp.PInvokeGenerator.<Close>g__GenerateNativeInheritanceAttribute|56_0(PInvokeGenerator generator, Stream stream, Boolean leaveStreamOpen) in /_/sources/ClangSharp.PInvokeGenerator/PInvokeGenerator.cs:line 367
   at ClangSharp.PInvokeGenerator.Close() in /_/sources/ClangSharp.PInvokeGenerator/PInvokeGenerator.cs:line 311
   at ClangSharp.PInvokeGenerator.Dispose(Boolean isDisposing) in /_/sources/ClangSharp.PInvokeGenerator/PInvokeGenerator.cs:line 1789
   at ClangSharp.PInvokeGenerator.Dispose() in /_/sources/ClangSharp.PInvokeGenerator/PInvokeGenerator.cs:line 1260
   at ClangSharp.Program.Run(InvocationContext context) in /_/sources/ClangSharpPInvokeGenerator/Program.cs:line 781
   at System.CommandLine.Handler.<>c__DisplayClass1_0`1.<SetHandler>b__0(InvocationContext context)
   at System.CommandLine.Invocation.AnonymousCommandHandler.<>c__DisplayClass2_0.<.ctor>g__Handle|0(InvocationContext context)
   at System.CommandLine.Invocation.AnonymousCommandHandler.InvokeAsync(InvocationContext context)
   at System.CommandLine.Invocation.InvocationPipeline.<>c__DisplayClass4_0.<<BuildInvocationChain>b__0>d.MoveNext()
--- End of stack trace from previous location ---
   at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass18_0.<<UseParseErrorReporting>b__0>d.MoveNext()
--- End of stack trace from previous location ---
   at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass13_0.<<UseHelp>b__0>d.MoveNext()
--- End of stack trace from previous location ---
   at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass20_0.<<UseTypoCorrections>b__0>d.MoveNext()
--- End of stack trace from previous location ---
   at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c.<<UseSuggestDirective>b__19_0>d.MoveNext()
--- End of stack trace from previous location ---
   at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass17_0.<<UseParseDirective>b__0>d.MoveNext()
--- End of stack trace from previous location ---
   at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c.<<RegisterWithDotnetSuggest>b__6_0>d.MoveNext()
--- End of stack trace from previous location ---
   at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass9_0.<<UseExceptionHandler>b__0>d.MoveNext()

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions