{"action":"created","issue":{"url":"https://api.github.com/repos/dotnet/corert/issues/977","repository_url":"https://api.github.com/repos/dotnet/corert","labels_url":"https://api.github.com/repos/dotnet/corert/issues/977/labels{/name}","comments_url":"https://api.github.com/repos/dotnet/corert/issues/977/comments","events_url":"https://api.github.com/repos/dotnet/corert/issues/977/events","html_url":"https://github.com/dotnet/corert/issues/977","id":138565955,"number":977,"title":"Native compilation: C++ code generation generates malformed float constants on german systems","user":{"login":"TimonChristl","id":7222046,"avatar_url":"https://avatars.githubusercontent.com/u/7222046?v=3","gravatar_id":"","url":"https://api.github.com/users/TimonChristl","html_url":"https://github.com/TimonChristl","followers_url":"https://api.github.com/users/TimonChristl/followers","following_url":"https://api.github.com/users/TimonChristl/following{/other_user}","gists_url":"https://api.github.com/users/TimonChristl/gists{/gist_id}","starred_url":"https://api.github.com/users/TimonChristl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TimonChristl/subscriptions","organizations_url":"https://api.github.com/users/TimonChristl/orgs","repos_url":"https://api.github.com/users/TimonChristl/repos","events_url":"https://api.github.com/users/TimonChristl/events{/privacy}","received_events_url":"https://api.github.com/users/TimonChristl/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/dotnet/corert/labels/UpForGrabs","name":"UpForGrabs","color":"159818"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2016-03-04T19:37:16Z","updated_at":"2016-03-11T17:43:40Z","closed_at":"2016-03-11T17:43:40Z","body":"The c++ code generator currently generates malformed float constants if the current culture formats floats with a comma as decimal separator instead of a dot (such as on german systems). This of course leads to the code not compiling. For example:\r\n\r\n```\r\n_bb847: {\r\n\r\n\tdouble _123 = _l11;\r\n\tdouble _124 = _123 + 1,84467440737096E+19;\r\n\t_l11 = _124;\r\n}\r\n\r\n```\r\nI tracked this down to the `.ToString()` call in `ImportLoadFloat()` in corert/src/ILCompiler.Compiler/src/CppCodeGen/ILToCppImporter.cs, which should be changed to `.ToString(CultureInfo.InvariantInfo)`, just like it is done in `ImportLoadInt()`."},"comment":{"url":"https://api.github.com/repos/dotnet/corert/issues/comments/195474613","html_url":"https://github.com/dotnet/corert/issues/977#issuecomment-195474613","issue_url":"https://api.github.com/repos/dotnet/corert/issues/977","id":195474613,"user":{"login":"jkotas","id":6668460,"avatar_url":"https://avatars.githubusercontent.com/u/6668460?v=3","gravatar_id":"","url":"https://api.github.com/users/jkotas","html_url":"https://github.com/jkotas","followers_url":"https://api.github.com/users/jkotas/followers","following_url":"https://api.github.com/users/jkotas/following{/other_user}","gists_url":"https://api.github.com/users/jkotas/gists{/gist_id}","starred_url":"https://api.github.com/users/jkotas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jkotas/subscriptions","organizations_url":"https://api.github.com/users/jkotas/orgs","repos_url":"https://api.github.com/users/jkotas/repos","events_url":"https://api.github.com/users/jkotas/events{/privacy}","received_events_url":"https://api.github.com/users/jkotas/received_events","type":"User","site_admin":false},"created_at":"2016-03-11T17:43:40Z","updated_at":"2016-03-11T17:43:40Z","body":"Fixed by #997 "}}