Details
-
Bug
-
Resolution: Cannot Reproduce
-
P3: Somewhat important
-
Qt Creator 4.9.2
-
None
-
x86_64
Description
When executing clang-format from QtCreator it removes or characters after parsing a string literal with Hindi characters. The characters seems to be Devanagari.
This is the file I am trying to format using the function <Format current file> in QtCreator 4.9.2:
#include <iostream> int main() { std::cout << "hello world in Hindi: " << "नमस्ते विश्व" << std::endl; return 0; }
After formatting with QtCreator the file cannot compile any longer:
#include <iostream> int main() { std::cout << "hello world in Hindi: " << "नमस्ते विश्व" << std::endl; rturn 0; }
You see that the u in "return" was removed when using the following clang-format file:
FixNamespaceComments: true TabWidth: 4 UseTab: Never #DisableFormat: true # When disabling nothing happens correctly
When I format the file the following way it gives the expected result:
clang-format --style=file -i main.cpp
#include <iostream> int main() { std::cout << "hello world in Hindi: " << "नमस्ते विश्व" << std::endl; return 0; }