[Development] Why we *have to* remove codecFor... ?

Thiago Macieira thiago.macieira at intel.com
Thu Jun 7 13:07:16 CEST 2012


On domingo, 22 de abril de 2012 12.49.59, Thiago Macieira wrote:
> So the solution to make everything work is:
>  1) always use UTF-8 encoded files
>  2) mark your US-ASCII strings with QLatin1String
>  3) everything else will either auto-convert, or use QString::fromUtf8 or 
>      QStringLiteral
> 
> Now, I *really*, really don't care about source code that doesn't follow 
> step 1. The C++ Standards Committee decided to give us Unicode strings (a
> very  modern action), but did not bother to specify the input character set
> for source code (a very 1980s action).
> 
> For that reason, considering that we live in a global world and that source 
> code is often shared among people in different countries. I am assuming
> that every developer will choose to use UTF-8 given the option and that
> every compiler and every text editor can understand it with minimal pain.
> 
> Any compiler or text editor that can't understand UTF-8 (without a BOM)
> will  receive from me the label of "crap" and will not take into
> consideration the problems users using them have with the plan above.

Oh well. That was good while it lasted.

	https://codereview.qt-project.org/#change,28086

MS didn't get the memo. MSVC 2010 meets my conditions for "crap".

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center
     Intel Sweden AB - Registration Number: 556189-6027
     Knarrarnäsgatan 15, 164 40 Kista, Stockholm, Sweden
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/development/attachments/20120607/e0f7305c/attachment.sig>


More information about the Development mailing list