User forums > Help

(solved) wchar_t problem

(1/1)

PeterP:
hi,
I just installed the official release (with included mingw compiler).
I wanted ro use a library that uses wchar_t strings alot.
but when I try to use special characters like umlauts (äöüßÄÖÜ) like this:
--- Code: ---wchar_t wc = L'ä'; // example with single character
--- End code ---
I get an error message sying: "converting to execution character set: Invalid argument"

I know I can use escape sequences, but it's hard to read in the source code and I also have to search for the correct hex value for the characters every time what's pretty boring... :(

with normal (char) strings I have no problem, I can enter this characters directly...
so now I'm wondering if I'm something missing to get this chars to work like with normal char strings ???  :shock:

thank you,
Peter

koso:
Try to use compiler switch "-finput-charset=<source charset>" in build options. More information about switch -> google :)

PeterP:
hahaha, I knew I was missing something !!!  :D
I used -finput-charset=iso-8859-1 and it works now !!!

thank you, very much !!! ;)

Navigation

[0] Message Index

Go to full version