Skip to main content

General questions and feedback on Microsoft's Quantum Developer Kit

Q# compiler fails with decimal separator other than .

As explained in https://github.com/Microsoft/Quantum/issues/6

Using a decimal separator other than . (i.e. "," for German computers) will fail to compile even the example libraries. The issue can be fixed by changing the separator, but this is breaking, as it will interfere with all other software on the computer.

By @StLange:
"That means there is at least one double to string conversion in the Q# compiler that misses CultureInfo.InvariantCulture and uses regional number format (German uses comma as decimal point)."

12 votes
Sign in
Signed in as (Sign out)

We’ll send you updates on this idea

Thomas H shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

4 comments

Sign in
Signed in as (Sign out)
Submitting...
  • Peter Kirchner commented  ·   ·  Flag as inappropriate

    After changing the number format to US. in my case it was sufficient to clean up the project via Build, Clean Solution. I did not have to reclone the project.

  • Don Heuvelman commented  ·   ·  Flag as inappropriate

    As a reaction on Federico Pasqua, thanks for the tip to DELETE the cloned repo first.. That was the key. I changed the Region to US but it still gave around 56 errors. After a while of searching I found your reaction on this site and the key was to remove the repo and clone it again in a clean folder. It now works as expected.

  • Federico Pasqua commented  ·   ·  Flag as inappropriate

    I can confirm the bug.
    Set Windows to use US number format (or use '.' as decimal separator), DELETE the cloned repo and re-clone it.

Feedback and Knowledge Base