indiantarget / quimeraengine

0 stars 0 forks source link

Move ToString method from basic data types to QStringUnicode constructor #610

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
SQInteger, SQFloat, SQBoolean and SQVF32 use the ToString method to convert a 
basic type to a string. It would be more usable to move these conversions to 
constructors of the QStringUnicode class. This way, when concatenating values 
in a string (for example, when mixing basic types and strings in a log message) 
conversions are made implicitly, being easier for a user to write such 
sentences. This avoids the necessity of including headers for basic type 
classes and looks clearer.

Original issue reported on code.google.com by Lince3D@gmail.com on 14 Nov 2014 at 12:28

GoogleCodeExporter commented 9 years ago
This task also includes the creation of a constructor that receives a f64_q 
type separately.

Original comment by Lince3D@gmail.com on 14 Nov 2014 at 3:30

GoogleCodeExporter commented 9 years ago
Instead of adding new constructors, which may add also a lot of complexity to 
the construction of a string, it could be better to add overloads to Append and 
operator+ methods, which would use internally the existing ToString methods. 
The point is to make value concatenation easier when printing a trace, for 
example.

Original comment by Lince3D@gmail.com on 11 Jan 2015 at 9:17

GoogleCodeExporter commented 9 years ago

Original comment by Lince3D@gmail.com on 2 Feb 2015 at 4:08

GoogleCodeExporter commented 9 years ago

Original comment by Lince3D@gmail.com on 9 Feb 2015 at 4:46

GoogleCodeExporter commented 9 years ago

Original comment by Lince3D@gmail.com on 10 Feb 2015 at 1:45