|
Archives
D Programming
digitalmars.Ddigitalmars.D.bugs digitalmars.D.dtl digitalmars.D.ide digitalmars.D.dwt digitalmars.D.announce digitalmars.D.learn digitalmars.D.debugger D.gnu D C/C++ Programming
c++c++.announce c++.atl c++.beta c++.chat c++.command-line c++.dos c++.dos.16-bits c++.dos.32-bits c++.idde c++.mfc c++.rtl c++.stl c++.stl.hp c++.stl.port c++.stl.sgi c++.stlsoft c++.windows c++.windows.16-bits c++.windows.32-bits c++.wxwindows digitalmars.empire digitalmars.DMDScript electronics |
digitalmars.D.learn - default opAssign(string) behaviour
Personally, I use (D1)std2.conv a lot to get values from strings and thus would love the following default behaviour for all types: int i = "0"; // i = 0 i = cast( int ) "0"; // i = 48 ( If I read the utf8 table correctly ) What keeps this from being the case? Jan 27 2010
On Thu, 28 Jan 2010 02:32:20 +0100, strtr <strtr spam.com> wrote:Personally, I use (D1)std2.conv a lot to get values from strings and thus would love the following default behaviour for all types: int i = "0"; // i = 0 i = cast( int ) "0"; // i = 48 ( If I read the utf8 table correctly ) What keeps this from being the case? Jan 28 2010
On 01/28/2010 02:32 AM, strtr wrote:Personally, I use (D1)std2.conv a lot to get values from strings and thus would love the following default behaviour for all types: int i = "0"; // i = 0 i = cast( int ) "0"; // i = 48 ( If I read the utf8 table correctly ) What keeps this from being the case? Jan 28 2010
On Wed, 27 Jan 2010 20:32:20 -0500, strtr <strtr spam.com> wrote:Personally, I use (D1)std2.conv a lot to get values from strings and thus would love the following default behaviour for all types: int i = "0"; // i = 0 Jan 28 2010
On Thu, 28 Jan 2010 09:02:12 +0100, Simen kjaeraas <simen.kjaras gmail.com> wrote:On Thu, 28 Jan 2010 02:32:20 +0100, strtr <strtr spam.com> wrote:Personally, I use (D1)std2.conv a lot to get values from strings and thus would love the following default behaviour for all types: int i = "0"; // i = 0 i = cast( int ) "0"; // i = 48 ( If I read the utf8 table correctly ) Jan 28 2010
|