]> git.lyx.org Git - lyx.git/commitdiff
squash gcc warning, secoind attempt
authorAndré Pönitz <poenitz@gmx.net>
Sat, 9 Feb 2008 10:16:54 +0000 (10:16 +0000)
committerAndré Pönitz <poenitz@gmx.net>
Sat, 9 Feb 2008 10:16:54 +0000 (10:16 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22888 a592a061-630c-0410-9148-cb99ea01b6c8

src/support/qstring_helpers.h

index 206d23948694693c48a5aee242e9f2ce08c307c1..39c824fcf378c4dda11e1dd91ab088604fff48c3 100644 (file)
@@ -72,7 +72,8 @@ inline QString const toqstr(docstring const & ucs4)
  */
 inline QString const toqstr(char_type ucs4)
 {
-       return QString::fromUcs4((uint const *)&ucs4, 1);
+       union { char_type c; uint i; } u = { ucs4 };
+       return QString::fromUcs4(&u.i, 1);
 }
 
 /**