|
Is it more important that I believe you have a heartbeat than I have a heartbeat ?
«There is a spectrum, from "clearly desirable behaviour," to "possibly dodgy behavior that still makes some sense," to "clearly undesirable behavior." We try to make the latter into warnings or, better, errors. But stuff that is in the middle category you don’t want to restrict unless there is a clear way to work around it.» Eric Lippert, May 14, 2008
|
|
|
|
|
Your resting heartbeat is telling you more than you think!
Regards,
Palash
|
|
|
|
|
If the mystics who preach that we, collectively, create the reality we experience from the maelstrom of potentiality that is Maya by our beliefs, what happens to your heartbeat if a majority of us cease to believe in its reality? Do you cease to exist, or do they?
Will Rogers never met me.
|
|
|
|
|
Another view is that the nature of that reality we don't see, because we are projections of it, is ceaseless change and transformation between opposites; is it as likely that the heartbeat is also created by a heartbeat reality, one that can (while we are comatose, or in deep sleep) not be perceived by us, yet exists (or, so we believe, or predict on the basis of experience and social consensus ?
These words by Giordano Bruno (eviscerated alive, then burned at the stake in 1600), and his other writings, his heliocentric astronomical beliefs, and teachings, were reasons he was convicted of heresy (he refused to recant, and, so, was condemned to be burned alive) are interesting:Quote: “The beginning, middle, and end of the birth, growth, and perfection of whatever we behold is from contraries, by contraries, and to contraries; and whatever contrariety is, there is action and reaction, there is motion, diversity, multitude, and order, there are degrees, succession and vicissitude.”
«There is a spectrum, from "clearly desirable behaviour," to "possibly dodgy behavior that still makes some sense," to "clearly undesirable behavior." We try to make the latter into warnings or, better, errors. But stuff that is in the middle category you don’t want to restrict unless there is a clear way to work around it.» Eric Lippert, May 14, 2008
|
|
|
|
|
Being a student of the Western Esoteric Tradition, e.g. a first degree mystic, I give you ten out of ten for that.
|
|
|
|
|
A heartbeat is, and is not.
If you have an important point to make, don't try to be subtle or clever. Use a pile driver. Hit the point once. Then come back and hit it again. Then hit it a third time - a tremendous whack.
--Winston Churchill
|
|
|
|
|
yep, but, a heartbeat has rhythm; if it loses the beat, your are not well.
«There is a spectrum, from "clearly desirable behaviour," to "possibly dodgy behavior that still makes some sense," to "clearly undesirable behavior." We try to make the latter into warnings or, better, errors. But stuff that is in the middle category you don’t want to restrict unless there is a clear way to work around it.» Eric Lippert, May 14, 2008
|
|
|
|
|
What does
return
{
a: "hello"
};
return?
(See A Collection of JavaScript Gotchas[^] for a hint.
I love finding something new about something I thought I understood.
cheers
Chris Maunder
|
|
|
|
|
doesn't it return?!
{
a: "hello"
}
The only confusion I can foresee is about what is this for the returned object...
Gotta read your link for hint on the trap!
|
|
|
|
|
The followup question is:
What does this return?
return {
a: "hello"
}
cheers
Chris Maunder
|
|
|
|
|
|
Super Lloyd wrote: I fail to see the tricky bit
Exactly.
Now try
return
{
a: "hello"
}
instead of
return {
a: "hello"
}
and let me know the difference.
cheers
Chris Maunder
|
|
|
|
|
OMG!!!
Yes, that's Javascrupt for ya!
|
|
|
|
|
...and this is why JavaScript needs to be retired in its current form. It's simply too loose a language.
cheers
Chris Maunder
|
|
|
|
|
Wow, so mere spacing can make a difference? Wtf! How do they even minify this with any expectation of consistency?
|
|
|
|
|
Nah, we just need to deprecate ASI. The community already shuns it, and I'm sure no one would bemoan its loss. Lots of JS devs are already fine with sticking 'use strict'; in all of their code. Let's just leverage that as a flag to tell the JS engine to turn it off.
modified 10-Oct-16 10:28am.
|
|
|
|
|
TypeScript FTW!
|
|
|
|
|
cheers
Chris Maunder
|
|
|
|
|
That's insane, Chris! You should make it a high priority to rewrite the site going back to VBScript. It worked fine then, and there's no reason that it would not work today, other than the overhead required to serve an additional 12 million members.
Will Rogers never met me.
|
|
|
|
|
Great findings there, Chris. I didn't know that it would make a difference when returning an object.
When writing JS code, I always do the K&R style of coding because I find it more clean and compact. I also do the same indention style with C#.
|
|
|
|
|
The tricky bit is here:
https://jsfiddle.net/vzmh2eL6/1/[^]
Returns `undefined`
Same thing happens if you use any other expression like:
return [1,2];
vs
return
[1,2];
This happens since based on Standard ECMA-262 5.1 Edition section [^]:
return [no LineTerminator here] Expression ;
we can not have any line terminators or new line between the return and the expression. If Expression is omitted, the return value is undefined. Otherwise, the return value is the value of Expression.
Hope it helps!
Regards,
Palash
modified 10-Oct-16 2:07am.
|
|
|
|
|
|
Palash Mondal_ wrote: This happens since based on Standard ECMA-262 5.1 Edition section [^]:
Actually, it is since the very beginning (v1.0). The end--of-line terminator was to help VB programmers; but it has caused all sorts of problems.
The issue is that there are effectively two forms of the return statement ...
return and
return expression;
|
|
|
|
|
You might like to see the difference between
var x =
{
a: 'Hello'
};
and
if (x)
{
a: 'hello'
};
The first creates an object (x) with a property (a) with a value ('hello')
The second is a statement with a label (a) pointing to an expression ('hello') which does nothing. Labels (except for case labels) are a feature that have never had any practical use in JavaScript.
|
|
|
|
|
Neat link, Chris! And an excellent job of discovery by Jonathan!
Will Rogers never met me.
|
|
|
|