Skip to content

error : syntax error at token '-' in: IL_002d: ldc.r8 -nan(ind) with "return Double.NaN" #158

Description

@tapika

Steps to reproduce:

Create demo project with function, which returns

return Double.NaN;
  • DllExport -version: 1.7.1
    With Visual studio 2017 it works. I have tried to start development prompt:
    C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC>where ildasm
    C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools\ildasm.exe

     C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC>ildasm /?|more
     Microsoft (R) .NET Framework IL Disassembler.  Version 4.0.30319.17929

Same code does not work with Visual Studio 2019.

    C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise>where ildasm
    C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8 Tools\ildasm.exe

    C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise>ildasm /? |more
    Microsoft (R) .NET Framework IL Disassembler.  Version 4.8.3928.0

I have tried to override this by modifying project settings and enforcing specific tool version, like this:

    <DllExportILAsmCustomPath>C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.7.2 Tools</DllExportILAsmCustomPath>

After that project compiled in both Visual studios.

Suspect some ildasm bug, at least looks somehow similar to:
#128 (comment)
=>

https://developercommunity.visualstudio.com/content/problem/545431/ildasmexe-regression-with-infinum-floating-point-v.html

Is this the same problem perhaps ?

I have vs2019 16.6.0, but there is update available, need to try it on.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions