August 01, 2014
On 08/01/2014 08:33 PM, Walter Bright wrote:
>
> The name came about as a result of my experience with newbies
> benchmarking my compilers and publishing the results. They'd spend 2 or
> 3 seconds scanning the documentation to figure out how to set up the
> compiler to generate the fastest code. -disableasserts is meaningless to
> them, and they won't use it, and the compiler would fare poorly.
> -release speaks to them "faster code", so they use that one.
>
> It's worked out well for that purpose.
> ...

Throw in -inline, -noboundscheck, -assumeasserts, -O, etc. and call the entire thing ...

-benchmark !

or ...

-fast !


> I would expect someone who spends more time developing code with the
> compiler to spend at least a little effort reading the two lines of
> documentation for -release and understanding that it disables the
> runtime assert checks.
> ...

Argh....

> I agree that the documentation can be improved.

August 01, 2014
On Fri, Aug 01, 2014 at 01:55:39PM -0700, Walter Bright via Digitalmars-d wrote:
> On 8/1/2014 12:09 PM, H. S. Teoh via Digitalmars-d wrote:
> >	A linguistics professor was lecturing to his class one day. "In
> >	English," he said, "A double negative forms a positive. In some
> >	languages, though, such as Russian, a double negative is still a
> >	negative. However, there is no language wherein a double
> >	positive can form a negative." A voice from the back of the room
> >	piped up, "Yeah, yeah."
> 
> English is quite the merry language with this. (Reversing the meaning
> of "merry", ho-ho!)
> 
> It's also why D doesn't support ! in version, and why I'm a strong advocate of not having negated features.
> 
> Of course, D has "no-throw" and "im-mutable". Arggh.

Well, if we could turn back the clock and redesign D based on our experience, we'd have "throwing" and "mutable" as modifiers instead of "nothrow" and "immutable". :)

Not to mention "impure" instead of "pure".


T

-- 
"Real programmers can write assembly code in any language. :-)" -- Larry Wall
August 01, 2014
On 08/01/2014 10:48 PM, Walter Bright wrote:
> On 8/1/2014 12:06 PM, Daniel Gibson wrote:
>>> For example, what would "sick" mean
>>> to a motorhead?
>>
>> You mean "motorhead" like in someone who likes cars or like in the the
>> heavy
>> metal band? :-P
>> (Non-native speakers probably associate motorhead with the band and
>> often don't
>> know the original meaning)
>
> "motorhead" as in someone who is happy with his head under the hood of a
> car working on the engine. (The band name is a reference to using
> amphetamine.)
>
> "sick" in this case would be a term of high praise for someone's custom
> hot rod.
>

Great. Now imagine you are a motorhead in a hospital.
August 01, 2014
On Friday, 1 August 2014 at 14:08:56 UTC, Daniel Gibson wrote:
> .. but even if I were: words used for constructs/function-names/... in programming often don't 100% match their "real" meaning (as used in human communication)[1] - why should it be different for assert(), especially when not implemented/used like that in many popular programming languages?

The way Walter is suggesting assert be handled is much more in line with the real English meaning (plus all of the resources posted seem to back up his position much more strongly than the other way), so that's why I'm siding with Walter on this (mostly). Imagine my surprise when I Google'd "assert definition" to find it meant "state a fact or belief confidently and forcefully."... the definition of the word really makes it obvious what the feature was originally intended to convey. Upon reflection, the definition that everyone is suggesting for assert ("something that is proven by being checked") really doesn't make a whole lot of sense given the facts laid out about assert.

Asserts are just facts that you state about the program. It's just a "nice feature" that the compiler will check your asserted facts when you're debugging your code. If you aren't stating a fact about the state/behavior of the code, you probably shouldn't be using an assert there (I feel that I've misused asserts from the beginning by not knowing this, though).
August 01, 2014
On 8/1/2014 2:00 PM, H. S. Teoh via Digitalmars-d wrote:
> And a "hot rod" in this context means a customized vehicle modified to
> have high performance, speed, etc., not a stick that has high
> temperature.  :-D

A hot rod also refers to a car with an American origin, whereas a "tuner" usually refers to a souped up imported car.

https://www.youtube.com/watch?v=3R7l7nDuj1o

https://www.youtube.com/watch?v=IAsdGE8XlZw

August 01, 2014
On Fri, Aug 01, 2014 at 11:08:53PM +0200, Timon Gehr via Digitalmars-d wrote:
> On 08/01/2014 10:48 PM, Walter Bright wrote:
> >On 8/1/2014 12:06 PM, Daniel Gibson wrote:
> >>>For example, what would "sick" mean
> >>>to a motorhead?
> >>
> >>You mean "motorhead" like in someone who likes cars or like in the the heavy metal band? :-P (Non-native speakers probably associate motorhead with the band and often don't know the original meaning)
> >
> >"motorhead" as in someone who is happy with his head under the hood of a car working on the engine. (The band name is a reference to using amphetamine.)
> >
> >"sick" in this case would be a term of high praise for someone's custom hot rod.
> >
> 
> Great. Now imagine you are a motorhead in a hospital.

I have no trouble distinguishing between these two meanings of "sick" within the same conversation. You just have to resolve your overload sets correctly. :-D


T

-- 
Ruby is essentially Perl minus Wall.
August 01, 2014
On 08/01/2014 11:18 PM, Chris Cain wrote:
> On Friday, 1 August 2014 at 14:08:56 UTC, Daniel Gibson wrote:
>> .. but even if I were: words used for constructs/function-names/... in
>> programming often don't 100% match their "real" meaning (as used in
>> human communication)[1] - why should it be different for assert(),
>> especially when not implemented/used like that in many popular
>> programming languages?
>
> The way Walter is suggesting assert be handled is much more in line with
> the real English meaning (plus all of the resources posted seem to back
> up his position much more strongly than the other way), so that's why
> I'm siding with Walter on this (mostly). Imagine my surprise when I
> Google'd "assert definition" to find it meant "state a fact or belief
> confidently and forcefully."... the definition of the word really makes
> it obvious what the feature was originally intended to convey. Upon
> reflection, the definition that everyone is suggesting for assert
> ("something that is proven by being checked") really doesn't make a
> whole lot of sense given the facts laid out about assert.
>
> Asserts are just facts that you state about the program. It's just a
> "nice feature" that the compiler will check your asserted facts when
> you're debugging your code. If you aren't stating a fact about the
> state/behavior of the code, you probably shouldn't be using an assert
> there (I feel that I've misused asserts from the beginning by not
> knowing this, though).

en.wikipedia.org/wiki/Evidence
August 01, 2014
On Fri, Aug 01, 2014 at 02:25:57PM -0700, Walter Bright via Digitalmars-d wrote:
> On 8/1/2014 2:00 PM, H. S. Teoh via Digitalmars-d wrote:
> >And a "hot rod" in this context means a customized vehicle modified to have high performance, speed, etc., not a stick that has high temperature.  :-D
> 
> A hot rod also refers to a car with an American origin, whereas a "tuner" usually refers to a souped up imported car.
[...]

And of course, a "tuner" means something entirely different to a musician. :-P


T

-- 
Right now I'm having amnesia and deja vu at the same time. I think I've forgotten this before.
August 01, 2014
On 08/01/2014 11:25 PM, H. S. Teoh via Digitalmars-d wrote:
>> Great. Now imagine you are a motorhead in a hospital.
> I have no trouble distinguishing between these two meanings of "sick"
> within the same conversation. You just have to resolve your overload
> sets correctly.:-D

The reason I was bringing this up was indeed that the current thread could be somewhat aptly summarized as one involving a motorhead who is trying to persuade a doctor that his patient is not actually sick, and that indeed, such a claim is completely meaningless; hence no medicine should be administered.
August 01, 2014
On Friday, 1 August 2014 at 21:29:48 UTC, Timon Gehr wrote:
> en.wikipedia.org/wiki/Evidence

http://en.wikipedia.org/wiki/Sausage

...

Sorry, I don't know what you meant by that. :-)