On Thursday 17 February 2011 23:09:32 Russel Winder wrote:
> On Thu, 2011-02-17 at 11:09 -0800, Walter Bright wrote:
> > Russel Winder wrote:
> > > Do not be afraid of the word. Fear leads to anger. Anger leads to
> > > hate. Hate leads to suffering. (*)
> > >
> > > (*) With apologies to Master
On Thu, 2011-02-17 at 11:09 -0800, Walter Bright wrote:
> Russel Winder wrote:
> > Do not be afraid of the word. Fear leads to anger. Anger leads to
> > hate. Hate leads to suffering. (*)
>
> > (*) With apologies to Master Yoda (**) for any misquote.
>
> "Luke, trust your feelings!" -- Oggie B
On 2/17/11 11:22 PM, Jonathan M Davis wrote:
On Thursday 17 February 2011 21:06:26 Jason House wrote:
Vladimir Panteleev Wrote:
int foo;
enum bar = foo+2;
void main()
{
foo = 7;
assert(bar == 9);
}
I would have expected bar to equal 2 since foo would be default initialized
Vladimir Panteleev wrote:
int foo;
enum bar = foo+2;
void main()
{
foo = 7;
assert(bar == 9);
}
It's bug 2414 "enum is dynamically evaluated, yum"
Sean Eskapp wrote:
Has this been reported?
struct A
{
int x;
A foo()
{
return A(x);
}
const bool opEquals(ref const A other)
{
return (x == other.x);
}
}
void main()
{
auto a = A(5);
assert
On Thursday 17 February 2011 21:23:26 Vladimir Panteleev wrote:
> On Fri, 18 Feb 2011 07:06:26 +0200, Jason House
>
> wrote:
> > I would have expected bar to equal 2 since foo would be default
> > initialized to 2. I'm going to guess that the there's some kind of
> > optimization that only assign
On Fri, 18 Feb 2011 07:06:26 +0200, Jason House
wrote:
I would have expected bar to equal 2 since foo would be default
initialized to 2. I'm going to guess that the there's some kind of
optimization that only assigns to foo once and isn't noticing that bar
depends on it.
Nope:
int foo
On Thursday 17 February 2011 21:06:26 Jason House wrote:
> Vladimir Panteleev Wrote:
> > int foo;
> > enum bar = foo+2;
> >
> > void main()
> > {
> >
> > foo = 7;
> > assert(bar == 9);
> >
> > }
>
> I would have expected bar to equal 2 since foo would be default initialized
> to 2. I'm
Sean Eskapp Wrote:
> Has this been reported?
Do what any of us would do... Search bugzilla and that as a bug if you don't
find it.
Vladimir Panteleev Wrote:
> int foo;
> enum bar = foo+2;
>
> void main()
> {
> foo = 7;
> assert(bar == 9);
> }
>
> --
> Best regards,
> Vladimirmailto:vladi...@thecybershadow.net
I would have expected bar to equal 2 since foo would be default initiali
int foo;
enum bar = foo+2;
void main()
{
foo = 7;
assert(bar == 9);
}
--
Best regards,
Vladimirmailto:vladi...@thecybershadow.net
Has this been reported?
struct A
{
int x;
A foo()
{
return A(x);
}
const bool opEquals(ref const A other)
{
return (x == other.x);
}
}
void main()
{
auto a = A(5);
assert(a == a.foo); // Erro
Nick Sabalausky wrote:
"Walter Bright" wrote in message
news:ijk6la$1d9a$1...@digitalmars.com...
Andrej Mitrovic wrote:
On 2/17/11, Walter Bright wrote:
Andrej Mitrovic wrote:
Is it true that you're not allowed to play with the segment registers
in 32bit flat protected mode?
Yes, that's th
"Walter Bright" wrote in message
news:ijk6la$1d9a$1...@digitalmars.com...
> Andrej Mitrovic wrote:
>> On 2/17/11, Walter Bright wrote:
>>> Andrej Mitrovic wrote:
Is it true that you're not allowed to play with the segment registers
in 32bit flat protected mode?
>>> Yes, that's the oper
"Stewart Gordon" wrote in message
news:ijgpgb$1apc$1...@digitalmars.com...
>
> And is [octal] still the form of CompuServe user IDs?
>
Do those still exist?
"Russel Winder" wrote in message
news:mailman.1748.1297936806.4748.digitalmar...@puremagic.com...
> A word is the natural length of an integer item in the processor.
> It is necessarily machine specific. cf. DEC-10 had 9-bit bytes
> and 36-bit word, IBM 370 has an 8-bit byte and a 32-bit word,
>
Andrej Mitrovic wrote:
On 2/17/11, Walter Bright wrote:
Andrej Mitrovic wrote:
Is it true that you're not allowed to play with the segment registers
in 32bit flat protected mode?
Yes, that's the operating system's job.
They took our jerbs!
You can always start your own company and hire y
On 2/17/11, Walter Bright wrote:
> Andrej Mitrovic wrote:
>> Is it true that you're not allowed to play with the segment registers
>> in 32bit flat protected mode?
>
> Yes, that's the operating system's job.
>
They took our jerbs!
Andrej Mitrovic wrote:
Is it true that you're not allowed to play with the segment registers
in 32bit flat protected mode?
Yes, that's the operating system's job.
Is it true that you're not allowed to play with the segment registers
in 32bit flat protected mode?
Kagamin wrote:
Walter Bright Wrote:
Actually, you can have a segmented model on a 32 bit machine rather than a
flat model, with separate segments for code, data, and stack. The Digital
Mars DOS Extender actually does this. The advantage of it is you cannot
execute data on the stack.
AFAIK you
Russel Winder wrote:
Do not be afraid of the word. Fear leads to anger. Anger leads to
hate. Hate leads to suffering. (*)
(*) With apologies to Master Yoda (**) for any misquote.
"Luke, trust your feelings!" -- Oggie Ben Doggie
Of course, expecting consistency from Star Wars is a waste o
On Thu, 17 Feb 2011 13:08:08 -0500, bearophile
wrote:
Steven Schveighoffer:
Yes, David has proposed a corrected version on the Phobos mailing list:
http://lists.puremagic.com/pipermail/phobos/2011-February/004493.html
I suggest it to return a signed value, like an int. But a signed long
Steven Schveighoffer:
> Yes, David has proposed a corrected version on the Phobos mailing list:
>
> http://lists.puremagic.com/pipermail/phobos/2011-February/004493.html
I suggest it to return a signed value, like an int. But a signed long is OK too.
I suggest a name as "len" (or "slen") because
Jacob Carlborg wrote:
I'm pretty sure that you can use the getter/setter syntax with
opDispatch, anything else is a bug.
You can only use one of the two, and yes, the bug is already
filed.
--
Simen
== Quote from Daniel Gibson (metalcae...@gmail.com)'s article
> It was not proposed to alter ulong (int64), but to only a size_t equivalent.
> ;)
> And I agree that not having unsigned types (like in Java) just sucks.
> Wasn't Java even advertised as a programming language for network stuff? Quite
On 2011-02-17 11:54, spir wrote:
On 02/17/2011 11:41 AM, Jacob Carlborg wrote:
On 2011-02-16 20:42, Christopher Nicholson-Sauls wrote:
On 02/13/11 10:30, Olli Aalto wrote:
I encountered a problem with alias this, when the aliased member is
private. I'm using the latest dmd2. It reports the fol
Le 17/02/2011 13:28, Don a écrit :
Yes, I know. It's true but I think rather useless.
We need a name for an 8 bit quantity, and a 16 bit quantity, and higher
powers of two. 'byte' is an established name for the first one, even
though historically there were 9-bit bytes. IMHO 'word' wasn't such a
dsimcha Wrote:
> Funny, as simple as it is, this is a great idea for std.array because it
> shortens the verbose cast(int) a.length to one extra character. You
> could even put an assert in it to check in debug mode only that the
> conversion is safe.
> > int ilength(void[] a) @property
> > {
On Thu, 17 Feb 2011 09:45:14 -0500, Kagamin wrote:
dsimcha Wrote:
Funny, as simple as it is, this is a great idea for std.array because it
shortens the verbose cast(int) a.length to one extra character. You
could even put an assert in it to check in debug mode only that the
conversion is saf
Funny, as simple as it is, this is a great idea for std.array because it
shortens the verbose cast(int) a.length to one extra character. You
could even put an assert in it to check in debug mode only that the
conversion is safe.
On 2/17/2011 7:18 AM, Kagamin wrote:
dsimcha Wrote:
Now that
Walter Bright Wrote:
> Actually, you can have a segmented model on a 32 bit machine rather than a
> flat
> model, with separate segments for code, data, and stack. The Digital Mars DOS
> Extender actually does this. The advantage of it is you cannot execute data
> on
> the stack.
AFAIK you i
Russel Winder wrote:
On Thu, 2011-02-17 at 10:13 +0100, Don wrote:
[ . . . ]
Me too. A word is two bytes. Any other definition seems to be pretty
useless.
Sounds like people have been living with 8- and 16-bit processors for
too long.
A word is the natural length of an integer item in the p
dsimcha Wrote:
> Now that DMD has a 64-bit beta available, I'm working on getting a whole bunch
> of code to compile in 64 mode. Frankly, the compiler is way too freakin'
> pedantic when it comes to implicit conversions (or lack thereof) of
> array.length. 99.999% of the time it's safe to assume
Adam Ruppe Wrote:
> alias iota lazyRangeThatGoesFromStartToFinishByTheGivenStepAmount;
Ever wondered, what iota is. At last it's self-documented.
spir wrote:
On 02/17/2011 10:13 AM, Don wrote:
David Nadlinger wrote:
On 2/17/11 8:56 AM, Denis Koroskin wrote:
I second that. word/uword are shorter than ssize_t/size_t and more in
line with other type names.
I like it.
I agree that size_t/ptrdiff_t are misnomers and I'd love to kill them
On 02/17/2011 11:41 AM, Jacob Carlborg wrote:
On 2011-02-16 20:42, Christopher Nicholson-Sauls wrote:
On 02/13/11 10:30, Olli Aalto wrote:
I encountered a problem with alias this, when the aliased member is
private. I'm using the latest dmd2. It reports the follwing:
src\main.d(14): Error: stru
On 2011-02-16 20:42, Christopher Nicholson-Sauls wrote:
On 02/13/11 10:30, Olli Aalto wrote:
I encountered a problem with alias this, when the aliased member is
private. I'm using the latest dmd2. It reports the follwing:
src\main.d(14): Error: struct K.K member s is not accessible
If I change
On 02/17/2011 10:13 AM, Don wrote:
David Nadlinger wrote:
On 2/17/11 8:56 AM, Denis Koroskin wrote:
I second that. word/uword are shorter than ssize_t/size_t and more in
line with other type names.
I like it.
I agree that size_t/ptrdiff_t are misnomers and I'd love to kill them with
fire, bu
On 02/17/2011 05:19 AM, Kevin Bealer wrote:
== Quote from spir (denis.s...@gmail.com)'s article
On 02/16/2011 03:07 AM, Jonathan M Davis wrote:
On Tuesday, February 15, 2011 15:13:33 spir wrote:
On 02/15/2011 11:24 PM, Jonathan M Davis wrote:
Is there some low level reason why size_t should b
On Thu, 2011-02-17 at 10:13 +0100, Don wrote:
[ . . . ]
> Me too. A word is two bytes. Any other definition seems to be pretty
> useless.
Sounds like people have been living with 8- and 16-bit processors for
too long.
A word is the natural length of an integer item in the processor. It is
nec
David Nadlinger wrote:
On 2/17/11 8:56 AM, Denis Koroskin wrote:
I second that. word/uword are shorter than ssize_t/size_t and more in
line with other type names.
I like it.
I agree that size_t/ptrdiff_t are misnomers and I'd love to kill them
with fire, but when I read about »word«, I intui
On 2/17/11 8:56 AM, Denis Koroskin wrote:
I second that. word/uword are shorter than ssize_t/size_t and more in
line with other type names.
I like it.
I agree that size_t/ptrdiff_t are misnomers and I'd love to kill them
with fire, but when I read about »word«, I intuitively associated it
wi
On Wed, 16 Feb 2011 06:49:26 +0300, Michel Fortin
wrote:
On 2011-02-15 22:41:32 -0500, "Nick Sabalausky" said:
I like "nint".
But is it unsigned or signed? Do we need 'unint' too?
I think 'word' & 'uword' would be a better choice. I can't say I'm too
displeased with 'size_t', but it's
44 matches
Mail list logo