clang变量名称的unicode字符

时间:2010-04-21 22:22:36

标签: unicode clang variable-names

cat test.cpp

#include <iostream>

int main() {
  int à;
}

结果:

clang++ test.cpp
test.cpp:4:7: error: expected unqualified-id
  int à;
      ^
1 error generated.

现在,有没有办法让clang允许unicode变量名?

谢谢!

1 个答案:

答案 0 :(得分:2)

虽然标准允许这样做,但Clang目前不支持标识符中的UCN(通用字符名称)。