|
PeejayAdams wrote: Indeed - and whatever the motivation, the end result is the same.
Not quite.. compare leaders like Churchill and Stalin.. very different outcomes to our corresponding countries.
Now is it bad enough that you let somebody else kick your butts without you trying to do it to each other? Now if we're all talking about the same man, and I think we are... it appears he's got a rather growing collection of our bikes.
modified 31-Aug-21 21:01pm.
|
|
|
|
|
Stalin was a grand-master with the airbrush and would be more effectively compared with Hitler who was also rather fond of rewriting the truth. Stalin was primarily motivated by ego, Hitler by a deranged ideology. Both were lying b******s who killed millions of innocent people - different motives, very similar results.
Churchill was, of course, a historian and not a man given to willful revisionism.
98.4% of statistics are made up on the spot.
|
|
|
|
|
And at the same time - under Churchill's leadership - the British public were also lied to..
So What Really Happened to our Railings?
One of many times, but all done with the aim of defending the country, winning the war and protecting our futures.. Lies, in fact, were essential to the war effort.
Different motives, different results..
Now is it bad enough that you let somebody else kick your butts without you trying to do it to each other? Now if we're all talking about the same man, and I think we are... it appears he's got a rather growing collection of our bikes.
modified 31-Aug-21 21:01pm.
|
|
|
|
|
The world isn't black and white and that's why it's better run by pragmatists rather than extremists. Churchill had the subtlety of mind to know when to do the right thing by doing the "wrong" thing - sadly, it's a very rare gift.
98.4% of statistics are made up on the spot.
|
|
|
|
|
It's not pragmatists that decided to overthrow governments in Libya, Afghanistan, Iraq, Ukraine.. and tried to in Syria.
Not that I'm a fan of any of their governments at the time, but a pragmatist would understand that you can't just go around toppling governments without consequences.
Now is it bad enough that you let somebody else kick your butts without you trying to do it to each other? Now if we're all talking about the same man, and I think we are... it appears he's got a rather growing collection of our bikes.
modified 31-Aug-21 21:01pm.
|
|
|
|
|
100% agree with that. It was the notion that a "one size fits all" democracy would suit the entire planet that has led to a lot of the current crises in the Middle East and North Africa.
The whole idea of "regime change" is simplistic and incomplete: Get rid of a tyrant - great! What happens next? Ah, we hadn't thought about that little details like that ...
98.4% of statistics are made up on the spot.
|
|
|
|
|
Quote: Not much mention of it here.. almost like it didn't happen That is so sad! June 6 1944 was one of the most significant days of the 20th century!
Get me coffee and no one gets hurt!
|
|
|
|
|
I linked to this in another reply here, but it's worth a look as it explains the situation here these days quite well..
Political correctness and the rewritng of history
Now is it bad enough that you let somebody else kick your butts without you trying to do it to each other? Now if we're all talking about the same man, and I think we are... it appears he's got a rather growing collection of our bikes.
modified 31-Aug-21 21:01pm.
|
|
|
|
|
Jeremy Falcon
|
|
|
|
|
Microsoft C#.
I set a function parameter (string myVar = string.Empty) and got:
Default parameter value for 'myVar' must be a compile-time constant
I fail to see how anything could be more constant than string.Empty....
|
|
|
|
|
String.Empty isn't a constant: it's a static readonly value.
Reference Source[^]
As such, it's value could depend on the initialization sequence in theory.
Anyway, "" is a lot clearer - and it's a constant!
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Yet another example of inaccurate code comments:
The Empty constant holds the empty string value.
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
So "" != String.Empty ?
Now is it bad enough that you let somebody else kick your butts without you trying to do it to each other? Now if we're all talking about the same man, and I think we are... it appears he's got a rather growing collection of our bikes.
modified 31-Aug-21 21:01pm.
|
|
|
|
|
Nope, it's much better!
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Wait, what? You know you can't get high on diesel.
Or are we still excited with that extra 40% per gallon by switching fuels?
Sin tack
the any key okay
|
|
|
|
|
Lopatir wrote: You know you can't get high on diesel.
Well, technically.. Continental Diesel
Now is it bad enough that you let somebody else kick your butts without you trying to do it to each other? Now if we're all talking about the same man, and I think we are... it appears he's got a rather growing collection of our bikes.
modified 31-Aug-21 21:01pm.
|
|
|
|
|
What!!! I've been extremely anal about using string.Empty instead of "" and you tell me it's the lesser option.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Run this code
if (ReferenceEquals(string.Empty, ""))
{
Console.WriteLine("\"\" is the same as String.Empty");
}
String.Empty and "" are likely to reference the same memory location so they are effectively the same (There's a name for this combining of string resources but I forget what it is). The problem with using String.Empty as a default value for a function parameter is that it's not a COMPILE time constant. The value stored in String.Empty is a reference to the string "" stored in memory and that reference doesn't get set until the program starts and the string "" gets loaded into memory. Because how can you have a reference to a memory location before the program has started?
So basically this error message is 100% accurate. It wanted a compile time constant but was given a runtime constant and it said "That's not good enough, mate".
|
|
|
|
|
I wasn't too serious
However, I think it would make sense if Microsoft actually allow parameters to have a default value of string.Empty instead of "". It's always been pushed as being a bad practice to have 'magic strings' in code.
Now is it bad enough that you let somebody else kick your butts without you trying to do it to each other? Now if we're all talking about the same man, and I think we are... it appears he's got a rather growing collection of our bikes.
modified 31-Aug-21 21:01pm.
|
|
|
|
|
It's not a constant.
From the CLI source:
public static readonly String Empty = "";
98.4% of statistics are made up on the spot.
|
|
|
|
|
If it is set to readonly so can never change, doesn't that make it constant?
|
|
|
|
|
No. A constant isn't actually a variable, it just looks like one. When you write this
const string x = "Hello";
if (x == "Hello")
{
Console.WriteLine (x);
}
what gets compiled is this;
if ("Hello" == "Hello")
{
Console.WriteLine ("Hello");
}
The compiler does a "find and replace" and in-lines the value of the constant. That is why a constant can't be an object.
const Person p = new Person();
p.Firstname = "John";
Console.WriteLine(p);
|
|
|
|
|
They work very differently and you can nuke a readonly with reflection. (and with unsafe , and in some odd corner cases with structs)
A constant is so constant that even if you have some constant in a DLL and you change it/recompile/replace the DLL, the application that uses the DLL still uses the old value. You also can't even try to change them with reflection, there is nothing there to attempt to write to.
A readonly is not directly writable, in all other ways it's a normal field.
|
|
|
|
|
Maybe we should have a modifier "SetOnceReadMany", to describe something that is not a "constant" in the sense of a literal, but will always return the same value when read. At least in a given run it returns the same value - not necessarily under varying conditions, such as moving your code to another operating system. The value is not modifiable (hence 'constant'), but depends on the OS (or some similar external condition.)
|
|
|
|
|
Does not help.
It still needs to store the string somewhere, even if the string is ""
and once it does that, (1) what's stored at that location can be externally modified after compilation and/or during execution.
Sin tack
the any key okay
|
|
|
|