Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #39859 > unrolled thread

I don't get it

Started byJonas Thörnvall <jonas.thornvall@gmail.com>
First post2021-04-08 03:32 -0700
Last post2021-04-10 00:01 -0700
Articles 20 on this page of 65 — 11 participants

Back to article view | Back to comp.lang.javascript


Contents

  I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-08 03:32 -0700
    Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-08 03:37 -0700
      Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-08 04:26 -0700
        Re: I don't get it JJ <jj4public@gmail.com> - 2021-04-08 19:39 +0700
          Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-08 05:53 -0700
            Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-08 13:55 -0700
              Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-09 00:46 -0700
                Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-09 10:03 +0100
                  Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-09 04:09 -0700
                  Re: I don't get it "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2021-04-09 11:07 -0700
                    Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-10 03:23 +0100
                      Re: I don't get it "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2021-04-10 22:02 -0700
                        Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-11 01:05 -0700
                          Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-11 01:07 -0700
                        Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-11 11:42 +0100
                  Re: I don't get it John G Harris <niam@jghnorth.org.uk.invalid> - 2021-04-09 20:01 +0100
                    Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-09 13:31 -0700
                    Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-10 03:37 +0100
                      Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-09 23:53 -0700
                      Re: I don't get it John G Harris <niam@jghnorth.org.uk.invalid> - 2021-04-10 12:05 +0100
                        Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-10 15:59 +0100
                      Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-10 15:47 +0100
                        Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-10 18:25 +0100
                          Re: I don't get it Jon Ribbens <jon+usenet@unequivocal.eu> - 2021-04-10 17:29 +0000
                          Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-10 19:08 +0100
                            Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-11 11:41 +0100
                              Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-11 14:33 +0100
                                Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-12 02:39 -0700
                                  Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-12 11:21 +0100
                                    Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-12 10:19 -0700
                                      Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-12 21:20 +0100
                                      Re: I don't get it "sc...@sauyet.com" <scott@sauyet.com> - 2021-04-12 14:32 -0700
                                        Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-13 04:11 -0700
                                          Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-13 14:58 +0100
                                            Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-13 09:20 -0700
                                              Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-13 09:29 -0700
                                              Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-13 20:06 +0100
                                              Re: I don't get it "sc...@sauyet.com" <scott@sauyet.com> - 2021-04-13 15:09 -0700
                                                Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-14 01:15 -0700
                                                  Re: I don't get it "sc...@sauyet.com" <scott@sauyet.com> - 2021-04-14 05:22 -0700
                                                    Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-15 11:52 -0700
                                                      Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-15 11:57 -0700
                                                        Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-15 12:04 -0700
                                                      Re: I don't get it Scott Sauyet <scott.sauyet@gmail.com> - 2021-04-15 19:29 -0700
                                                        Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-20 14:12 -0700
                                                          Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-20 14:47 -0700
                                                            Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-20 23:35 -0700
                                                              Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-21 01:08 -0700
                                                                Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-21 01:24 -0700
                                                                  Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-21 01:29 -0700
                                            Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-13 09:32 -0700
                                            Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-13 21:59 +0100
                                              Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-14 01:32 +0100
                                                Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-14 09:08 +0100
                                                  Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-14 10:06 +0100
                                                    Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-14 10:59 +0100
                                                      Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-14 14:05 +0100
                                                        Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-14 16:32 +0100
                                                          Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-14 23:53 +0100
                                                            Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-15 13:56 +0100
                                Re: I don't get it The Natural Philosopher <tnp@invalid.invalid> - 2021-04-12 11:20 +0100
          Re: I don't get it Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-04-08 15:21 +0100
            Re: I don't get it Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2021-04-09 16:50 +0200
    Re: I don't get it Man From a city with name Viljandi <he12457@hotmail.com> - 2021-04-08 10:44 -0700
    Re: I don't get it Jonas Thörnvall <jonas.thornvall@gmail.com> - 2021-04-10 00:01 -0700

Page 1 of 4  [1] 2 3 4  Next page →


#39859 — I don't get it

FromJonas Thörnvall <jonas.thornvall@gmail.com>
Date2021-04-08 03:32 -0700
SubjectI don't get it
Message-ID<db867da0-d12e-4658-bbfc-f988789a42fan@googlegroups.com>
https://jonasth.github.io/
Please have a look, i do subtract the latency from the next upcoming event don't i???????????


function STARTPLAY(){
	if (keepGoing) {
		stopRec=setTimeout(STARTPLAY,copyEv[playPos]);
		//While still notes
		if (playPos<copyEv.length) {
			//******THIS CODE WILL CORRECT, THE FUTURE TIMING OF NEXT EVENT
			//The realtime that passed is performance.now()-browserLoadTIME
			//The scheduled time is the note timings schedTime=copyEv[playPos]+schedTime;
			//Realtime-scheduledtime is our latency.
			//calculate latency=performance.now()-browserLoadTIME-schedTime; 	
			//calculate new position copyEv[playPos]=copyEv[playPos]-latency; 		
			ctm.font = "26px Arial";
			ctm.fillStyle="blue";
			ctm.fillRect(50,40,500,500);
			ctm.fillStyle="white";
			ctm.fillText("Sum scheduled "+schedTime, 50, 70);
			REALTIME=performance.now()-browserLoadTIME;
			ctm.fillText("Real time "+REALTIME, 50, 90);
			LATENCY=REALTIME-schedTime;
			ctm.fillText("Latency "+LATENCY, 50, 110);
			schedTime=copyEv[playPos]+schedTime; 
			ctm.fillText("Orig TIME Ev "+copyEv[playPos], 50, 130);			
			copyEv[playPos]=Math.max(0,copyEv[playPos]-LATENCY);
			ctm.fillText("New TIME Ev "+copyEv[playPos], 50, 150);
			reshed=copyEv[playPos]+reshed;
			ctm.fillText("Reshed time "+reshed, 50, 170);
			outportarr[outportindex].send(noteMessage[playPos]);
			oldPassedTime=schedTime;
			playPos++;	
			if (echo && mode=="Play"){ 
				pianoKeypressOut();
			}
		} else { stop();}
	}
}

[toc] | [next] | [standalone]


#39860

FromJonas Thörnvall <jonas.thornvall@gmail.com>
Date2021-04-08 03:37 -0700
Message-ID<bb267a9e-7e6c-461a-8c97-a99a999fd154n@googlegroups.com>
In reply to#39859
torsdag 8 april 2021 kl. 12:32:12 UTC+2 skrev Jonas Thörnvall:
> https://jonasth.github.io/ 
> Please have a look, i do subtract the latency from the next upcoming event don't i??????????? 
> 
> 
> function STARTPLAY(){ 
> if (keepGoing) { 
> stopRec=setTimeout(STARTPLAY,copyEv[playPos]); 
> //While still notes 
> if (playPos<copyEv.length) { 
> //******THIS CODE WILL CORRECT, THE FUTURE TIMING OF NEXT EVENT 
> //The realtime that passed is performance.now()-browserLoadTIME 
> //The scheduled time is the note timings schedTime=copyEv[playPos]+schedTime; 
> //Realtime-scheduledtime is our latency. 
> //calculate latency=performance.now()-browserLoadTIME-schedTime; 
> //calculate new position copyEv[playPos]=copyEv[playPos]-latency; 
> ctm.font = "26px Arial"; 
> ctm.fillStyle="blue"; 
> ctm.fillRect(50,40,500,500); 
> ctm.fillStyle="white"; 
> ctm.fillText("Sum scheduled "+schedTime, 50, 70); 
> REALTIME=performance.now()-browserLoadTIME; 
> ctm.fillText("Real time "+REALTIME, 50, 90); 
> LATENCY=REALTIME-schedTime; 
> ctm.fillText("Latency "+LATENCY, 50, 110); 
> schedTime=copyEv[playPos]+schedTime; 
> ctm.fillText("Orig TIME Ev "+copyEv[playPos], 50, 130); 
> copyEv[playPos]=Math.max(0,copyEv[playPos]-LATENCY); 
> ctm.fillText("New TIME Ev "+copyEv[playPos], 50, 150); 
> reshed=copyEv[playPos]+reshed; 
> ctm.fillText("Reshed time "+reshed, 50, 170); 
> outportarr[outportindex].send(noteMessage[playPos]); 
> oldPassedTime=schedTime; 
> playPos++; 
> if (echo && mode=="Play"){ 
> pianoKeypressOut(); 
> } 
> } else { stop();} 
> } 
> }
If  I from every note remove the accumulated latency, "time" how can the latency still keep on adding up, there is temporal distances  between the notes??????

[toc] | [prev] | [next] | [standalone]


#39861

FromJonas Thörnvall <jonas.thornvall@gmail.com>
Date2021-04-08 04:26 -0700
Message-ID<d08a6beb-026a-4657-817e-b4ddcba5b73an@googlegroups.com>
In reply to#39860
torsdag 8 april 2021 kl. 12:37:25 UTC+2 skrev Jonas Thörnvall:
> torsdag 8 april 2021 kl. 12:32:12 UTC+2 skrev Jonas Thörnvall: 
> > https://jonasth.github.io/ 
> > Please have a look, i do subtract the latency from the next upcoming event don't i??????????? 
> > 
> > 
> > function STARTPLAY(){ 
> > if (keepGoing) { 
> > stopRec=setTimeout(STARTPLAY,copyEv[playPos]); 
> > //While still notes 
> > if (playPos<copyEv.length) { 
> > //******THIS CODE WILL CORRECT, THE FUTURE TIMING OF NEXT EVENT 
> > //The realtime that passed is performance.now()-browserLoadTIME 
> > //The scheduled time is the note timings schedTime=copyEv[playPos]+schedTime; 
> > //Realtime-scheduledtime is our latency. 
> > //calculate latency=performance.now()-browserLoadTIME-schedTime; 
> > //calculate new position copyEv[playPos]=copyEv[playPos]-latency; 
> > ctm.font = "26px Arial"; 
> > ctm.fillStyle="blue"; 
> > ctm.fillRect(50,40,500,500); 
> > ctm.fillStyle="white"; 
> > ctm.fillText("Sum scheduled "+schedTime, 50, 70); 
> > REALTIME=performance.now()-browserLoadTIME; 
> > ctm.fillText("Real time "+REALTIME, 50, 90); 
> > LATENCY=REALTIME-schedTime; 
> > ctm.fillText("Latency "+LATENCY, 50, 110); 
> > schedTime=copyEv[playPos]+schedTime; 
> > ctm.fillText("Orig TIME Ev "+copyEv[playPos], 50, 130); 
> > copyEv[playPos]=Math.max(0,copyEv[playPos]-LATENCY); 
> > ctm.fillText("New TIME Ev "+copyEv[playPos], 50, 150); 
> > reshed=copyEv[playPos]+reshed; 
> > ctm.fillText("Reshed time "+reshed, 50, 170); 
> > outportarr[outportindex].send(noteMessage[playPos]); 
> > oldPassedTime=schedTime; 
> > playPos++; 
> > if (echo && mode=="Play"){ 
> > pianoKeypressOut(); 
> > } 
> > } else { stop();} 
> > } 
> > }
> If I from every note remove the accumulated latency, "time" how can the latency still keep on adding up, there is temporal distances between the notes??????
Do anyone understand my code?
More importantly why it behave like it does?
Because i don't.
But we do have a realtime clock, and our playpos is a future event "so i think we must compare RT with previous scheduled event which is actually now?"

function STARTPLAY(){
	if (keepGoing) {
		//While still notes
		if (playPos<copyEv.length) {
			//******THIS CODE WILL CORRECT, THE FUTURE TIMING OF NEXT EVENT
			//The realtime that passed is performance.now()-browserLoadTIME
			//The scheduled time is the note timings schedTime=copyEv[playPos]+schedTime;
			//Realtime-scheduledtime is our latency.
			//calculate latency=performance.now()-browserLoadTIME-schedTime; 	
			//calculate new position copyEv[playPos]=copyEv[playPos]-latency; 	
			stopRec=setTimeout(STARTPLAY,copyEv[playPos]);
			REALTIME=performance.now()-browserLoadTIME;
			LATENCY=REALTIME-oldPassedTime;			
			drawLatency();
			oldPassedTime=schedTime;
			schedTime=copyEv[playPos]+schedTime; 
			copyEv[playPos]=Math.max(0,copyEv[playPos]-LATENCY);
			drawCorrection();
			outportarr[outportindex].send(noteMessage[playPos]);
			playPos++;	
			if (echo && mode=="Play"){ 
				pianoKeypressOut();
			}
		} else { stop();}
			
	}
}

function drawLatency(){
		ctm.font = "26px Arial";
		ctm.fillStyle="blue";
		ctm.fillRect(50,40,500,500);
		ctm.fillStyle="white";
		ctm.fillText("Sum scheduled "+schedTime, 50, 70);
		ctm.fillText("Real time "+REALTIME, 50, 90);
		ctm.fillText("Latency "+LATENCY, 50, 110);
		ctm.fillText("Orig TIME Ev "+copyEv[playPos], 50, 130);	
		
	
}

function drawCorrection(){
		ctm.fillStyle="yellow";			
		ctm.fillText("New TIME Ev "+copyEv[playPos], 50, 150);
		reshed=copyEv[playPos]+reshed;
		ctm.fillText("Reshed time "+reshed, 50, 170);
}

[toc] | [prev] | [next] | [standalone]


#39862

FromJJ <jj4public@gmail.com>
Date2021-04-08 19:39 +0700
Message-ID<1e965vkgenq7l$.hqmrkifgr4m5$.dlg@40tude.net>
In reply to#39861
On Thu, 8 Apr 2021 04:26:12 -0700 (PDT), Jonas Thörnvall wrote:
> Do anyone understand my code?

Frankly, I don't bother checking an incomplete and untestable code.

[toc] | [prev] | [next] | [standalone]


#39863

FromJonas Thörnvall <jonas.thornvall@gmail.com>
Date2021-04-08 05:53 -0700
Message-ID<586d1b88-77d5-42b0-ae5b-7506307df499n@googlegroups.com>
In reply to#39862
torsdag 8 april 2021 kl. 14:40:13 UTC+2 skrev JJ:
> On Thu, 8 Apr 2021 04:26:12 -0700 (PDT), Jonas Thörnvall wrote: 
> > Do anyone understand my code?
> Frankly, I don't bother checking an incomplete and untestable code.
Everything you need to know, you can see in script,
You see the values before and after transformation
https://jonasth.github.io/

[toc] | [prev] | [next] | [standalone]


#39866

FromJonas Thörnvall <jonas.thornvall@gmail.com>
Date2021-04-08 13:55 -0700
Message-ID<957a79db-946e-4f23-931a-ef7d4f0dbb3cn@googlegroups.com>
In reply to#39863
torsdag 8 april 2021 kl. 14:53:08 UTC+2 skrev Jonas Thörnvall:
> torsdag 8 april 2021 kl. 14:40:13 UTC+2 skrev JJ: 
> > On Thu, 8 Apr 2021 04:26:12 -0700 (PDT), Jonas Thörnvall wrote: 
> > > Do anyone understand my code? 
> > Frankly, I don't bother checking an incomplete and untestable code.
> Everything you need to know, you can see in script, 
> You see the values before and after transformation 
> https://jonasth.github.io/
Actually i spotted a problem, for me checking the latency work because i have a midi keyboard connected, It is a bit of pain having two playup routines adjust code for soundfont synth or external midi device.
I will try fix it once for all tomorrow, but since i always work with the keyboards plugged in i do not see it until i unplug them.

[toc] | [prev] | [next] | [standalone]


#39867

FromJonas Thörnvall <jonas.thornvall@gmail.com>
Date2021-04-09 00:46 -0700
Message-ID<305fecc4-43da-4378-8430-ed10ac4dbe5bn@googlegroups.com>
In reply to#39866
torsdag 8 april 2021 kl. 22:55:37 UTC+2 skrev Jonas Thörnvall:
> torsdag 8 april 2021 kl. 14:53:08 UTC+2 skrev Jonas Thörnvall: 
> > torsdag 8 april 2021 kl. 14:40:13 UTC+2 skrev JJ: 
> > > On Thu, 8 Apr 2021 04:26:12 -0700 (PDT), Jonas Thörnvall wrote: 
> > > > Do anyone understand my code? 
> > > Frankly, I don't bother checking an incomplete and untestable code. 
> > Everything you need to know, you can see in script, 
> > You see the values before and after transformation 
> > https://jonasth.github.io/
> Actually i spotted a problem, for me checking the latency work because i have a midi keyboard connected, It is a bit of pain having two playup routines adjust code for soundfont synth or external midi device. 
> I will try fix it once for all tomorrow, but since i always work with the keyboards plugged in i do not see it until i unplug them.

Ok now i fixed drawout out of the latency for people without midi devices.
I start to suspect it is a recursion thing.

"Press play"
Here is the other internal synth playup.

function SF2Playup() {
	if (keepGoing) {
		stopRec=setTimeout(SF2Playup, copyEv[playPos]);
		if (playPos<copyEv.length) {
			REALTIME=performance.now()-browserLoadTIME;
			LATENCY=REALTIME-oldPassedTime;			
			drawLatency();
			oldPassedTime=schedTime;
			schedTime=copyEv[playPos]+schedTime; 
			copyEv[playPos]=Math.max(0,copyEv[playPos]-LATENCY);
			drawCorrection();
			if (track[playtrack].midiMess[playPos].data0 > 143 && track[playtrack].midiMess[playPos].data0 < 160) {
				synth.NoteOn(track[playtrack].midiMess[playPos].data0,track[playtrack].midiMess[playPos].data1,track[playtrack].midiMess[playPos].data2);
			} else if (track[playtrack].midiMess[playPos].data0 > 127 && track[playtrack].midiMess[playPos].data0 < 144) {
				synth.NoteOff(track[playtrack].midiMess[playPos].data0,track[playtrack].midiMess[playPos].data1);
			} else if (track[playtrack].midiMess[playPos].data0 > 191 && track[playtrack].midiMess[playPos].data0 < 208) {
				synth.PGMchange(track[playtrack].midiMess[playPos].data0,track[playtrack].midiMess[playPos].data1);
			} else {
				synth.NoteOn(track[playtrack].midiMess[playPos].data0,track[playtrack].midiMess[playPos].data1,track[playtrack].midiMess[playPos].data2);
			}

			if (echo && mode=="Play"){ 
				pianoKeypressOut();
			}	
			playPos++;
		} else { stop();}
	}
}

[toc] | [prev] | [next] | [standalone]


#39868

FromThe Natural Philosopher <tnp@invalid.invalid>
Date2021-04-09 10:03 +0100
Message-ID<s4p58i$g2u$1@dont-email.me>
In reply to#39867
On 09/04/2021 08:46, Jonas Thörnvall wrote:
> Ok now i fixed drawout out of the latency for people without midi devices.
> I start to suspect it is a recursion thing.

After spending two days some years ago I discovered that IE and Firefox 
differed in their handling of comparisons of numerical and string data, 
and that something like

if('1'== 1)

was handled differently in each browser.

As with all loosely typed languages, bugs in your code are trumped by 
bugs in the language itself.

JavaScript is an unadulterated pile of object oriented wombat turds, but 
since it is all we have, we have to discover how to make it work...

In assembler, there is only one possible meaning for each machine 
instruction. Any bugs are in your code, not in the language (though they 
might be in the hardware itself).

The essentially unstructured nature of the code itself *forces* you to 
adopt a disciplined structured well commented approach if you are to 
have a hope in hell of maintaining it.

Attempts by academics to write perfect languages that will do all this 
for you just lead to unexpected side effects.
Memory leak bugs are replaced by asynchronous garbage collection side 
effects. Loose typing that reduces the need for coders to think about 
what they are actually saying with a variable declaration (if indeed the 
language requires them to be declared at all) removes compile time type 
errors at the expense of introducing arbitrary run time errors... . 
Variable bit packing in stream data cannot be easily handled with masks 
and shifts, since the the declarations insist that something is a an int 
or a string, not a random collection of bits that may need to be treated 
as either, depending on context.

Local variables - a wonderful invention in C (and other similar 
languages), that were ephemeral and needed no garbage collection at all, 
but opened up the possibility of stamping all over the stack with 
gloriously self modifying code...

Just reading one page from a national newspaper results in 100% CPU 
usage and stuttering. Yes, it's JavaShit™...

If one half the cleverness (I hesitate to say intelligence) involved in 
learning a complex language were instead applied to learning the 
discipline of software engineering, the world would have a lot less 
buggy code in it.

I have after 5 years of unfixed bugs, decided to leave Barclays Smart 
Investors website and close my account, since by some cleverness that I 
am unable to elucidate, it will always at a given point detect that any 
browser running on linux 'is out of date', log you out and clear all the 
session cookies. JavaScript of course. How it probes the OS I don't 
know, but it does, because the same browsers running on Windows work 
(reasonably) fine.

And because the site is written using third party tools (I assume) by 
ArtStudents™  who have learnt the tool, but not how to program, the bugs 
are unfixable, because they are in the tools itself.

And they need a tool, because javaScript, or indeed basic HTML is to 
hard for their art student brains.

In addition for the last three years a pop up red warning flag tells me 
I have two urgent messages waiting. The warning persists even with the 
messages page open clearly stating 'you have no messages'.


Sigh. I've seen it happen time and again. Postscript. Not a page 
description language. Oh no. Postscript is a fully functioned 'I can do 
everything' *programming* language that at one time required  the apple 
printer to have more memory and computing power than  the desktop 
publishing Apple computer that drove it.

Years later I can still produce PDFS that wont print..for reasons I cant 
establish.

Or let's take X - windows. Perhaps the biggest pile of shit that was 
ever invented by academic computer scientists with nothing better to do.

It can do anything, except the one thing most people want
it to do, provide a stable low resource munching graphical display on 
*nix style computers. 99% of its functionality is never used, and its 
complexity is hidden - sometimes successfully  - behind 'toolkits' that 
provide some (slightly) simpler (but still massively complex) interface 
to the very few of its features anyone actually needs or wants.

HTML was a wonderfully clear and simple language for the web.
Until bored computer scientists invented 'active pages'
Sigh.

Here we go again. Bugs, workarounds. Fixes. Frameworks and languages and 
developer tools, and what you see simply never appears on the printer..

What you don't see is intelligent programmers that understand the tools 
they have , what hardware is and how it works, and what the human 
problem they are trying to solve actually consists of.

When constructing a web form, always style it so that the submit button 
has a one pixel very light grey on white  bordered 'flat' modern look 
and exists on a completely arbitrary place on the web page from the data 
it is supposed to submit. And the web page itself features pastel 
minority race individuals enjoying their happy clappy 'investing 
experience' as backgrounds, utterly obscuring the data entry or display...

What is the worst possible way to enter data to a computer that you 
could possibly think of - after a mouse, that is?

A touch screen.

I think I'll commit suicide.


-- 
  “A leader is best When people barely know he exists. Of a good leader, 
who talks little,When his work is done, his aim fulfilled,They will say, 
“We did this ourselves.”

― Lao Tzu, Tao Te Ching

[toc] | [prev] | [next] | [standalone]


#39869

FromJonas Thörnvall <jonas.thornvall@gmail.com>
Date2021-04-09 04:09 -0700
Message-ID<65867d5a-a282-44a7-a5eb-6899755bb904n@googlegroups.com>
In reply to#39868
fredag 9 april 2021 kl. 11:03:21 UTC+2 skrev The Natural Philosopher:
> On 09/04/2021 08:46, Jonas Thörnvall wrote: 
> > Ok now i fixed drawout out of the latency for people without midi devices. 
> > I start to suspect it is a recursion thing.
> After spending two days some years ago I discovered that IE and Firefox 
> differed in their handling of comparisons of numerical and string data, 
> and that something like 
> 
> if('1'== 1) 
> 
> was handled differently in each browser. 
> 
> As with all loosely typed languages, bugs in your code are trumped by 
> bugs in the language itself. 
> 
> JavaScript is an unadulterated pile of object oriented wombat turds, but 
> since it is all we have, we have to discover how to make it work... 
> 
> In assembler, there is only one possible meaning for each machine 
> instruction. Any bugs are in your code, not in the language (though they 
> might be in the hardware itself). 
> 
> The essentially unstructured nature of the code itself *forces* you to 
> adopt a disciplined structured well commented approach if you are to 
> have a hope in hell of maintaining it. 
> 
> Attempts by academics to write perfect languages that will do all this 
> for you just lead to unexpected side effects. 
> Memory leak bugs are replaced by asynchronous garbage collection side 
> effects. Loose typing that reduces the need for coders to think about 
> what they are actually saying with a variable declaration (if indeed the 
> language requires them to be declared at all) removes compile time type 
> errors at the expense of introducing arbitrary run time errors... . 
> Variable bit packing in stream data cannot be easily handled with masks 
> and shifts, since the the declarations insist that something is a an int 
> or a string, not a random collection of bits that may need to be treated 
> as either, depending on context. 
> 
> Local variables - a wonderful invention in C (and other similar 
> languages), that were ephemeral and needed no garbage collection at all, 
> but opened up the possibility of stamping all over the stack with 
> gloriously self modifying code... 
> 
> Just reading one page from a national newspaper results in 100% CPU 
> usage and stuttering. Yes, it's JavaShit™... 
> 
> If one half the cleverness (I hesitate to say intelligence) involved in 
> learning a complex language were instead applied to learning the 
> discipline of software engineering, the world would have a lot less 
> buggy code in it. 
> 
> I have after 5 years of unfixed bugs, decided to leave Barclays Smart 
> Investors website and close my account, since by some cleverness that I 
> am unable to elucidate, it will always at a given point detect that any 
> browser running on linux 'is out of date', log you out and clear all the 
> session cookies. JavaScript of course. How it probes the OS I don't 
> know, but it does, because the same browsers running on Windows work 
> (reasonably) fine. 
> 
> And because the site is written using third party tools (I assume) by 
> ArtStudents™ who have learnt the tool, but not how to program, the bugs 
> are unfixable, because they are in the tools itself. 
> 
> And they need a tool, because javaScript, or indeed basic HTML is to 
> hard for their art student brains. 
> 
> In addition for the last three years a pop up red warning flag tells me 
> I have two urgent messages waiting. The warning persists even with the 
> messages page open clearly stating 'you have no messages'. 
> 
> 
> Sigh. I've seen it happen time and again. Postscript. Not a page 
> description language. Oh no. Postscript is a fully functioned 'I can do 
> everything' *programming* language that at one time required the apple 
> printer to have more memory and computing power than the desktop 
> publishing Apple computer that drove it. 
> 
> Years later I can still produce PDFS that wont print..for reasons I cant 
> establish. 
> 
> Or let's take X - windows. Perhaps the biggest pile of shit that was 
> ever invented by academic computer scientists with nothing better to do. 
> 
> It can do anything, except the one thing most people want 
> it to do, provide a stable low resource munching graphical display on 
> *nix style computers. 99% of its functionality is never used, and its 
> complexity is hidden - sometimes successfully - behind 'toolkits' that 
> provide some (slightly) simpler (but still massively complex) interface 
> to the very few of its features anyone actually needs or wants. 
> 
> HTML was a wonderfully clear and simple language for the web. 
> Until bored computer scientists invented 'active pages' 
> Sigh. 
> 
> Here we go again. Bugs, workarounds. Fixes. Frameworks and languages and 
> developer tools, and what you see simply never appears on the printer.. 
> 
> What you don't see is intelligent programmers that understand the tools 
> they have , what hardware is and how it works, and what the human 
> problem they are trying to solve actually consists of. 
> 
> When constructing a web form, always style it so that the submit button 
> has a one pixel very light grey on white bordered 'flat' modern look 
> and exists on a completely arbitrary place on the web page from the data 
> it is supposed to submit. And the web page itself features pastel 
> minority race individuals enjoying their happy clappy 'investing 
> experience' as backgrounds, utterly obscuring the data entry or display... 
> 
> What is the worst possible way to enter data to a computer that you 
> could possibly think of - after a mouse, that is? 
> 
> A touch screen. 
> 
> I think I'll commit suicide. 
> 
> 
> -- 
> “A leader is best When people barely know he exists. Of a good leader, 
> who talks little,When his work is done, his aim fulfilled,They will say, 
> “We did this ourselves.” 
> 
> ― Lao Tzu, Tao Te Ching
Well maybe you could make a qualified guess, i can't because my knowledge about the language, and even the recursive backend calling itself is very poor.
Press "play"
https://jonasth.github.io/
function SF2Playup() {
if (keepGoing) {
stopRec=setTimeout(SF2Playup, copyEv[playPos]);
if (playPos<copyEv.length) {
REALTIME=performance.now()-browserLoadTIME;
LATENCY=REALTIME-oldPassedTime;
drawLatency();
oldPassedTime=schedTime;
schedTime=copyEv[playPos]+schedTime;
copyEv[playPos]=Math.max(0,copyEv[playPos]-LATENCY);
drawCorrection();
if (track[playtrack].midiMess[playPos].data0 > 143 && track[playtrack].midiMess[playPos].data0 < 160) {
synth.NoteOn(track[playtrack].midiMess[playPos].data0,track[playtrack].midiMess[playPos].data1,track[playtrack].midiMess[playPos].data2);
} else if (track[playtrack].midiMess[playPos].data0 > 127 && track[playtrack].midiMess[playPos].data0 < 144) {
synth.NoteOff(track[playtrack].midiMess[playPos].data0,track[playtrack].midiMess[playPos].data1);
} else if (track[playtrack].midiMess[playPos].data0 > 191 && track[playtrack].midiMess[playPos].data0 < 208) {
synth.PGMchange(track[playtrack].midiMess[playPos].data0,track[playtrack].midiMess[playPos].data1);
} else {
synth.NoteOn(track[playtrack].midiMess[playPos].data0,track[playtrack].midiMess[playPos].data1,track[playtrack].midiMess[playPos].data2);
}

if (echo && mode=="Play"){
pianoKeypressOut();
}
playPos++;
} else { stop();}
}
}

[toc] | [prev] | [next] | [standalone]


#39874

From"Michael Haufe (TNO)" <tno@thenewobjective.com>
Date2021-04-09 11:07 -0700
Message-ID<bd76e11c-8774-47d3-ab7d-2545e1068740n@googlegroups.com>
In reply to#39868
On Friday, April 9, 2021 at 4:03:21 AM UTC-5, The Natural Philosopher wrote:
> On 09/04/2021 08:46, Jonas Thörnvall wrote: 
> > Ok now i fixed drawout out of the latency for people without midi devices. 
> > I start to suspect it is a recursion thing.
> After spending two days some years ago I discovered that IE and Firefox 
> differed in their handling of comparisons of numerical and string data, 
> and that something like 
> 
> if('1'== 1) 
> 
> was handled differently in each browser. 

I don't believe you. Coercions have been clear since 1996 in this regard [1]

The only  unspecified differences at that time were that:

JavaScript 1.1 as implemented in Navigator 3.0 converted NaN to true and the empty string to 0

This was resolved as part of the first standard specification. Microsoft reverse engineered the Netscape implementation and shared the behavior.

Internet Explorer had 97% market share by the end of the first browser war. Firefox was forked from Netscape's code. 

> As with all loosely typed languages, bugs in your code are trumped by 
> bugs in the language itself. 

If there are bugs in the language it doesn't matter what the typing methodology is.

> JavaScript is an unadulterated pile of object oriented wombat turds, but 
> since it is all we have, we have to discover how to make it work... 

I don't think you know what "object oriented" means.

> In assembler, there is only one possible meaning for each machine 
> instruction. Any bugs are in your code, not in the language (though they 
> might be in the hardware itself). 

Nonsense:

<https://en.wikipedia.org/wiki/Halt_and_Catch_Fire_(computing)>

> The essentially unstructured nature of the code itself *forces* you to 
> adopt a disciplined structured well commented approach if you are to 
> have a hope in hell of maintaining it. 

All you're doing is playing the role of compiler and computer, running the program in your head.
This is less reliable than the computer and does not scale, therefore the wrong approach.

> Attempts by academics to write perfect languages that will do all this 
> for you just lead to unexpected side effects. 

Having actually done this work and written compilers and formal proofs of Type Systems I definitely prefer that to your ad-hoc "disciplined" approach.

Also, there is no "perfect" language per Gödel [2]. I'd be surprised if you can find someone in the field who believes otherwise.

> Memory leak bugs are replaced by asynchronous garbage collection side 
> effects.

umm... do you know how garbage collection works? [3]

> Loose typing that reduces the need for coders to think about 
> what they are actually saying with a variable declaration (if indeed the 
> language requires them to be declared at all) removes compile time type 
> errors at the expense of introducing arbitrary run time errors... . 

You're confusing Dynamic typing with Weak typing. You're also ignoring the existence of type inference in static type systems.

> Variable bit packing in stream data cannot be easily handled with masks 
> and shifts, since the the declarations insist that something is a an int 
> or a string, not a random collection of bits that may need to be treated 
> as either, depending on context. 

If you're dealing with external data via I/O, any data stream has to be interrogated. Just claiming it's an "int" by declaration in a static system does not make it true. The same issue when dealing with nullable objects. Blindly dereferencing without checking is foolhardy regardless of the typing approach.

> Local variables - a wonderful invention in C (and other similar 
> languages), that were ephemeral and needed no garbage collection at all, 
> but opened up the possibility of stamping all over the stack with 
> gloriously self modifying code... 

If can use malloc in C though which uses the heap. Now *YOU* get to play the role of garbage collector. 
Do you think you can do better than what was referenced in [3]? Can you do better at scale and across multiple programs, some of which you do not control? I doubt it.

> Just reading one page from a national newspaper results in 100% CPU 
> usage and stuttering. Yes, it's JavaShit™... 

What does that have to do with the language? I can write a spinlock in all ALGOL family languages. At least JS is memory safe.
Are you old enough to remember this?

<http://users.csc.calpoly.edu/~jdalbey/SWE/Papers/att_collapse.html>

> If one half the cleverness (I hesitate to say intelligence) involved in 
> learning a complex language were instead applied to learning the 
> discipline of software engineering, the world would have a lot less 
> buggy code in it. 

Agreed, mostly.

> I have after 5 years of unfixed bugs, decided to leave Barclays Smart 
> Investors website and close my account, since by some cleverness that I 
> am unable to elucidate, it will always at a given point detect that any 
> browser running on linux 'is out of date', log you out and clear all the 
> session cookies.

You know you can change your User Agent right? Install a plugin.

> JavaScript of course.

Not a JavaScript problem.

> How it probes the OS I don't 
> know, but it does, because the same browsers running on Windows work 
> (reasonably) fine. 

<https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent>
 
> And because the site is written using third party tools (I assume) by 
> ArtStudents™ who have learnt the tool, but not how to program, the bugs 
> are unfixable, because they are in the tools itself. 
> 
> And they need a tool, because javaScript, or indeed basic HTML is to 
> hard for their art student brains. 

It's sounding like they aren't alone the way this rant is going...

> In addition for the last three years a pop up red warning flag tells me 
> I have two urgent messages waiting. The warning persists even with the 
> messages page open clearly stating 'you have no messages'. 

Is there a point to all of this?

> Sigh. I've seen it happen time and again. Postscript. Not a page 
> description language. Oh no. Postscript is a fully functioned 'I can do 
> everything' *programming* language that at one time required the apple 
> printer to have more memory and computing power than the desktop 
> publishing Apple computer that drove it. 
> 
> Years later I can still produce PDFS that wont print..for reasons I cant 
> establish. 

PEBCAK, or maybe stop using a dot matrix printer?

> Or let's take X - windows. Perhaps the biggest pile of shit that was 
> ever invented by academic computer scientists with nothing better to do. 
> 
> It can do anything, except the one thing most people want 
> it to do, provide a stable low resource munching graphical display on 
> *nix style computers. 99% of its functionality is never used, and its 
> complexity is hidden - sometimes successfully - behind 'toolkits' that 
> provide some (slightly) simpler (but still massively complex) interface 
> to the very few of its features anyone actually needs or wants. 

You're off in the weeds now. What does any of this have to do with JavaScript?

> HTML was a wonderfully clear and simple language for the web. 
> Until bored computer scientists invented 'active pages' 
> Sigh. 

ASP? Last I checked "Computer Scientists" didn't create that.

> Here we go again. Bugs, workarounds. Fixes. Frameworks and languages and 
> developer tools, and what you see simply never appears on the printer.. 

FFS get to the point...

> What you don't see is intelligent programmers that understand the tools 
> they have , what hardware is and how it works, and what the human 
> problem they are trying to solve actually consists of. 

Do you include yourself in that category? I mean, if you want to write assembly code for everything and not use garbage collection, and want your banking website to render in your mystery browser good luck. It might take you awhile to reinvent a number of architectures and in 20 years when you finish who will care? At least to made it the way you want it though right?

> When constructing a web form, always style it so that the submit button 
> has a one pixel very light grey on white bordered 'flat' modern look 
> and exists on a completely arbitrary place on the web page from the data 
> it is supposed to submit. And the web page itself features pastel 
> minority race individuals enjoying their happy clappy 'investing 
> experience' as backgrounds, utterly obscuring the data entry or display... 

yes, okay?

> What is the worst possible way to enter data to a computer that you 
> could possibly think of - after a mouse, that is? 

Whatever web browser your using I guess.

> A touch screen. 
> 
> I think I'll commit suicide. 

PEBCAK


[1] - "JavaScript: The First 20 Years" <https://dl.acm.org/doi/pdf/10.1145/3386327>
[2] - "Gödel's incompleteness theorems" <https://en.wikipedia.org/wiki/G%C3%B6del%27s_incompleteness_theorems>
[3] - "Uniprocessor garbage collection techniques" <https://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.231.5655>

[toc] | [prev] | [next] | [standalone]


#39877

FromThe Natural Philosopher <tnp@invalid.invalid>
Date2021-04-10 03:23 +0100
Message-ID<s4r26j$ddu$1@dont-email.me>
In reply to#39874
On 09/04/2021 19:07, Michael Haufe (TNO) wrote:
> On Friday, April 9, 2021 at 4:03:21 AM UTC-5, The Natural Philosopher wrote:
>> On 09/04/2021 08:46, Jonas Thörnvall wrote:
>>> Ok now i fixed drawout out of the latency for people without midi devices.
>>> I start to suspect it is a recursion thing.
>> After spending two days some years ago I discovered that IE and Firefox
>> differed in their handling of comparisons of numerical and string data,
>> and that something like
>>
>> if('1'== 1)
>>
>> was handled differently in each browser.
> I don't believe you. Coercions have been clear since 1996 in this regard [1]

Well you can fuck off then. I cant remember the exact case, but it 
involved a conditional and an implicit cast inside it. Firefox and IE6 
simply didn't handle the case the same.

I looked at the language spec for implicit casting, and the language 
spec simply didn't cover this particular case.



-- 
WOKE is an acronym... Without Originality, Knowledge or Education.

[toc] | [prev] | [next] | [standalone]


#39891

From"Michael Haufe (TNO)" <tno@thenewobjective.com>
Date2021-04-10 22:02 -0700
Message-ID<58e4f84b-811a-4174-977d-bc72edbd060en@googlegroups.com>
In reply to#39877
On Friday, April 9, 2021 at 9:23:22 PM UTC-5, The Natural Philosopher wrote:
> On 09/04/2021 19:07, Michael Haufe (TNO) wrote: 
> > On Friday, April 9, 2021 at 4:03:21 AM UTC-5, The Natural Philosopher wrote: 
> >> On 09/04/2021 08:46, Jonas Thörnvall wrote: 
> >>> Ok now i fixed drawout out of the latency for people without midi devices. 
> >>> I start to suspect it is a recursion thing. 
> >> After spending two days some years ago I discovered that IE and Firefox 
> >> differed in their handling of comparisons of numerical and string data, 
> >> and that something like 
> >> 
> >> if('1'== 1) 
> >> 
> >> was handled differently in each browser. 
> > I don't believe you. Coercions have been clear since 1996 in this regard [1]
> Well you can fuck off then. I cant remember the exact case, but it 
> involved a conditional and an implicit cast inside it. Firefox and IE6 
> simply didn't handle the case the same. 
> 
> I looked at the language spec for implicit casting, and the language 
> spec simply didn't cover this particular case. 

I don't care if you misremember something, I do care when you spread FUD on a false premise.

[toc] | [prev] | [next] | [standalone]


#39893

FromJonas Thörnvall <jonas.thornvall@gmail.com>
Date2021-04-11 01:05 -0700
Message-ID<e47bce65-7c15-4d70-ba97-8020260f39d1n@googlegroups.com>
In reply to#39891
söndag 11 april 2021 kl. 07:03:02 UTC+2 skrev Michael Haufe (TNO):
> On Friday, April 9, 2021 at 9:23:22 PM UTC-5, The Natural Philosopher wrote: 
> > On 09/04/2021 19:07, Michael Haufe (TNO) wrote: 
> > > On Friday, April 9, 2021 at 4:03:21 AM UTC-5, The Natural Philosopher wrote: 
> > >> On 09/04/2021 08:46, Jonas Thörnvall wrote: 
> > >>> Ok now i fixed drawout out of the latency for people without midi devices. 
> > >>> I start to suspect it is a recursion thing. 
> > >> After spending two days some years ago I discovered that IE and Firefox 
> > >> differed in their handling of comparisons of numerical and string data, 
> > >> and that something like 
> > >> 
> > >> if('1'== 1) 
> > >> 
> > >> was handled differently in each browser. 
> > > I don't believe you. Coercions have been clear since 1996 in this regard [1] 
> > Well you can fuck off then. I cant remember the exact case, but it 
> > involved a conditional and an implicit cast inside it. Firefox and IE6 
> > simply didn't handle the case the same. 
> > 
> > I looked at the language spec for implicit casting, and the language 
> > spec simply didn't cover this particular case.
> I don't care if you misremember something, I do care when you spread FUD on a false premise.
Make a qualified guess, i can't because my knowledge about the language, and even the recursive backend calling itself is very poor.
Press "play"
https://jonasth.github.io/

[toc] | [prev] | [next] | [standalone]


#39894

FromJonas Thörnvall <jonas.thornvall@gmail.com>
Date2021-04-11 01:07 -0700
Message-ID<7ece7ea3-cf26-4501-8d48-93b24a0058e3n@googlegroups.com>
In reply to#39893
söndag 11 april 2021 kl. 10:05:33 UTC+2 skrev Jonas Thörnvall:
> söndag 11 april 2021 kl. 07:03:02 UTC+2 skrev Michael Haufe (TNO): 
> > On Friday, April 9, 2021 at 9:23:22 PM UTC-5, The Natural Philosopher wrote: 
> > > On 09/04/2021 19:07, Michael Haufe (TNO) wrote: 
> > > > On Friday, April 9, 2021 at 4:03:21 AM UTC-5, The Natural Philosopher wrote: 
> > > >> On 09/04/2021 08:46, Jonas Thörnvall wrote: 
> > > >>> Ok now i fixed drawout out of the latency for people without midi devices. 
> > > >>> I start to suspect it is a recursion thing. 
> > > >> After spending two days some years ago I discovered that IE and Firefox 
> > > >> differed in their handling of comparisons of numerical and string data, 
> > > >> and that something like 
> > > >> 
> > > >> if('1'== 1) 
> > > >> 
> > > >> was handled differently in each browser. 
> > > > I don't believe you. Coercions have been clear since 1996 in this regard [1] 
> > > Well you can fuck off then. I cant remember the exact case, but it 
> > > involved a conditional and an implicit cast inside it. Firefox and IE6 
> > > simply didn't handle the case the same. 
> > > 
> > > I looked at the language spec for implicit casting, and the language 
> > > spec simply didn't cover this particular case. 
> > I don't care if you misremember something, I do care when you spread FUD on a false premise.
> Make a qualified guess, i can't because my knowledge about the language, and even the recursive backend calling itself is very poor. 
> Press "play" 
> https://jonasth.github.io/
Just answer the question about what goes wrong and what one could to about it and we can leave this thread.

[toc] | [prev] | [next] | [standalone]


#39899

FromThe Natural Philosopher <tnp@invalid.invalid>
Date2021-04-11 11:42 +0100
Message-ID<s4ujrj$r1a$2@dont-email.me>
In reply to#39891
On 11/04/2021 06:02, Michael Haufe (TNO) wrote:
> On Friday, April 9, 2021 at 9:23:22 PM UTC-5, The Natural Philosopher wrote:
>> On 09/04/2021 19:07, Michael Haufe (TNO) wrote:
>>> On Friday, April 9, 2021 at 4:03:21 AM UTC-5, The Natural Philosopher wrote:
>>>> On 09/04/2021 08:46, Jonas Thörnvall wrote:
>>>>> Ok now i fixed drawout out of the latency for people without midi devices.
>>>>> I start to suspect it is a recursion thing.
>>>> After spending two days some years ago I discovered that IE and Firefox
>>>> differed in their handling of comparisons of numerical and string data,
>>>> and that something like
>>>>
>>>> if('1'== 1)
>>>>
>>>> was handled differently in each browser.
>>> I don't believe you. Coercions have been clear since 1996 in this regard [1]
>> Well you can fuck off then. I cant remember the exact case, but it
>> involved a conditional and an implicit cast inside it. Firefox and IE6
>> simply didn't handle the case the same.
>>
>> I looked at the language spec for implicit casting, and the language
>> spec simply didn't cover this particular case.
> 
> I don't care if you misremember something, I do care when you spread FUD on a false premise.
> 
It is not false and I do not misremember.

I found the code and it is now littered with explicit casts . I wouldn't 
have done that without good reason.


-- 
I would rather have questions that cannot be answered...
...than to have answers that cannot be questioned

Richard Feynman

[toc] | [prev] | [next] | [standalone]


#39875

FromJohn G Harris <niam@jghnorth.org.uk.invalid>
Date2021-04-09 20:01 +0100
Message-ID<20917gl3dv8shs6qqf1dqginq69e50aa54@4ax.com>
In reply to#39868
On Fri, 9 Apr 2021 10:03:13 +0100, The Natural Philosopher
<tnp@invalid.invalid> wrote:

  <snip>
>After spending two days some years ago I discovered that IE and Firefox 
>differed in their handling of comparisons of numerical and string data, 
>and that something like
>
>if('1'== 1)
>
>was handled differently in each browser.
>
>As with all loosely typed languages, bugs in your code are trumped by 
>bugs in the language itself.

Was that before or after they claimed to conform to ECMA 262? If
after, one or both browsers had a bug, not the language. If before,
that's what you get with USPs.

  <snip>
>In assembler, there is only one possible meaning for each machine 
>instruction. Any bugs are in your code, not in the language (though they 
>might be in the hardware itself).

Have you ever tried to understand what Edit And Mark does, and how to
make use of it?


>The essentially unstructured nature of the code itself *forces* you to 
>adopt a disciplined structured well commented approach if you are to 
>have a hope in hell of maintaining it.

By golly, what a lot of optimism.


  <snip>
>Local variables - a wonderful invention in C (and other similar 
>languages), that were ephemeral and needed no garbage collection at all, 
>but opened up the possibility of stamping all over the stack with 
>gloriously self modifying code...

It's recursion that absolutely requires a stack. It's not local
variables. They only use a stack to save the program occupying so much
space that the program won't load.


>Just reading one page from a national newspaper results in 100% CPU 
>usage and stuttering. Yes, it's JavaShit™...

One sentence, advert, one sentence, advert, one sentence, advert, ...
That's marketing.


  <snip>
>Postscript. Not a page 
>description language. Oh no. Postscript is a fully functioned 'I can do 
>everything' *programming* language
  <snip>

Postscript is a wonderful language. It produced a graph that
accurately showed the weird data rate vs block length of a mag tape
drive that didn't have a big enough data buffer.


  <snip>
>HTML was a wonderfully clear and simple language for the web.
>Until bored computer scientists invented 'active pages'

Until marketing demanded 'engaging' web pages.


  <snip>
>What you don't see is intelligent programmers that understand the tools 
>they have , what hardware is and how it works, and what the human 
>problem they are trying to solve actually consists of.

After 20 years, some web sites allow you to write a credit card number
the way it's written on the card - a space every 4 digits - so it's
easy to check. But it's still a minority. <End of mini-rant> 
  <snip>

  John

[toc] | [prev] | [next] | [standalone]


#39876

FromJonas Thörnvall <jonas.thornvall@gmail.com>
Date2021-04-09 13:31 -0700
Message-ID<eb146b98-c823-497a-b231-31b44d236b09n@googlegroups.com>
In reply to#39875
fredag 9 april 2021 kl. 21:01:49 UTC+2 skrev John G Harris:
> On Fri, 9 Apr 2021 10:03:13 +0100, The Natural Philosopher 
> <t...@invalid.invalid> wrote: 
> 
> <snip>
> >After spending two days some years ago I discovered that IE and Firefox 
> >differed in their handling of comparisons of numerical and string data, 
> >and that something like 
> > 
> >if('1'== 1) 
> > 
> >was handled differently in each browser. 
> > 
> >As with all loosely typed languages, bugs in your code are trumped by 
> >bugs in the language itself.
> Was that before or after they claimed to conform to ECMA 262? If 
> after, one or both browsers had a bug, not the language. If before, 
> that's what you get with USPs. 
> 
> <snip>
> >In assembler, there is only one possible meaning for each machine 
> >instruction. Any bugs are in your code, not in the language (though they 
> >might be in the hardware itself).
> Have you ever tried to understand what Edit And Mark does, and how to 
> make use of it?
> >The essentially unstructured nature of the code itself *forces* you to 
> >adopt a disciplined structured well commented approach if you are to 
> >have a hope in hell of maintaining it.
> By golly, what a lot of optimism. 
> 
> 
> <snip>
> >Local variables - a wonderful invention in C (and other similar 
> >languages), that were ephemeral and needed no garbage collection at all, 
> >but opened up the possibility of stamping all over the stack with 
> >gloriously self modifying code...
> It's recursion that absolutely requires a stack. It's not local 
> variables. They only use a stack to save the program occupying so much 
> space that the program won't load.
> >Just reading one page from a national newspaper results in 100% CPU 
> >usage and stuttering. Yes, it's JavaShit™...
> One sentence, advert, one sentence, advert, one sentence, advert, ... 
> That's marketing. 
> 
> 
> <snip>
> >Postscript. Not a page 
> >description language. Oh no. Postscript is a fully functioned 'I can do 
> >everything' *programming* language
> <snip> 
> 
> Postscript is a wonderful language. It produced a graph that 
> accurately showed the weird data rate vs block length of a mag tape 
> drive that didn't have a big enough data buffer. 
> 
> 
> <snip>
> >HTML was a wonderfully clear and simple language for the web. 
> >Until bored computer scientists invented 'active pages'
> Until marketing demanded 'engaging' web pages. 
> 
> 
> <snip>
> >What you don't see is intelligent programmers that understand the tools 
> >they have , what hardware is and how it works, and what the human 
> >problem they are trying to solve actually consists of.
> After 20 years, some web sites allow you to write a credit card number 
> the way it's written on the card - a space every 4 digits - so it's 
> easy to check. But it's still a minority. <End of mini-rant> 
> <snip> 
> 
> John
Maybe you could make a qualified guess, i can't because my knowledge about the language, and even the recursive backend calling itself is very poor.
Press "play"
https://jonasth.github.io/

[toc] | [prev] | [next] | [standalone]


#39878

FromThe Natural Philosopher <tnp@invalid.invalid>
Date2021-04-10 03:37 +0100
Message-ID<s4r30i$i9b$1@dont-email.me>
In reply to#39875
On 09/04/2021 20:01, John G Harris wrote:
> On Fri, 9 Apr 2021 10:03:13 +0100, The Natural Philosopher
> <tnp@invalid.invalid> wrote:
> 
>    <snip>
>> After spending two days some years ago I discovered that IE and Firefox
>> differed in their handling of comparisons of numerical and string data,
>> and that something like
>>
>> if('1'== 1)
>>
>> was handled differently in each browser.
>>
>> As with all loosely typed languages, bugs in your code are trumped by
>> bugs in the language itself.
> 
> Was that before or after they claimed to conform to ECMA 262? If
> after, one or both browsers had a bug, not the language. If before,
> that's what you get with USPs.

It was around 2007 give or take. IE6 and XP was current. I coded for 
firefox, it broke in IE6.

I actually checked the language spec. As far as I cam remember the spec 
was explicit, that you converted to whatever the target of an 
assignement was in a mixed type operation, but in a conditional there 
was no assignment type...

> 
>    <snip>
>> In assembler, there is only one possible meaning for each machine
>> instruction. Any bugs are in your code, not in the language (though they
>> might be in the hardware itself).
> 
> Have you ever tried to understand what Edit And Mark does, and how to
> make use of it?
> 
> 
>> The essentially unstructured nature of the code itself *forces* you to
>> adopt a disciplined structured well commented approach if you are to
>> have a hope in hell of maintaining it.
> 
> By golly, what a lot of optimism.
Well sure, there si a lot of unstructrured muck out there, thgat is 
unmaintainable.
#
> 
> 
>    <snip>
>> Local variables - a wonderful invention in C (and other similar
>> languages), that were ephemeral and needed no garbage collection at all,
>> but opened up the possibility of stamping all over the stack with
>> gloriously self modifying code...
> 
> It's recursion that absolutely requires a stack. It's not local
> variables. They only use a stack to save the program occupying so much
> space that the program won't load.

That is rubbish. They use the stack because the destruction of them is 
automatic on exit from a subroutine. Otherwise you have to compile some 
fancy code to free up the space they use.
> 
> 
>> Just reading one page from a national newspaper results in 100% CPU
>> usage and stuttering. Yes, it's JavaShit™...
> 
> One sentence, advert, one sentence, advert, one sentence, advert, ...
> That's marketing.
> 

That JavaShit makes possible
> 
>    <snip>
>> Postscript. Not a page
>> description language. Oh no. Postscript is a fully functioned 'I can do
>> everything' *programming* language
>    <snip>
> 
> Postscript is a wonderful language. It produced a graph that
> accurately showed the weird data rate vs block length of a mag tape
> drive that didn't have a big enough data buffer.

I guess thats something we all do every day.

> 
> 
>    <snip>
>> HTML was a wonderfully clear and simple language for the web.
>> Until bored computer scientists invented 'active pages'
> 
> Until marketing demanded 'engaging' web pages.
> 
Ah the old Microsoft paradigm
"Designed to sell, but not to work"

> 
>    <snip>
>> What you don't see is intelligent programmers that understand the tools
>> they have , what hardware is and how it works, and what the human
>> problem they are trying to solve actually consists of.
> 
> After 20 years, some web sites allow you to write a credit card number
> the way it's written on the card - a space every 4 digits - so it's
> easy to check. But it's still a minority. <End of mini-rant>

Precisely.

Programs that ask you what country you are in and then will not let you 
proceed without entering a USA specific zip code...

...that will not let you enter anything but alpha in a name field, and 
then barf because the hyphenated name on your credit card is not matched 
by what you typed in....


>    <snip>
> 
>    John
> 


-- 
New Socialism consists essentially in being seen to have your heart in 
the right place whilst your head is in the clouds and your hand is in 
someone else's pocket.

[toc] | [prev] | [next] | [standalone]


#39879

FromJonas Thörnvall <jonas.thornvall@gmail.com>
Date2021-04-09 23:53 -0700
Message-ID<6b2208a5-6ffe-4248-8649-a9653d767c70n@googlegroups.com>
In reply to#39878
lördag 10 april 2021 kl. 04:37:13 UTC+2 skrev The Natural Philosopher:
> On 09/04/2021 20:01, John G Harris wrote: 
> > On Fri, 9 Apr 2021 10:03:13 +0100, The Natural Philosopher 
> > <t...@invalid.invalid> wrote: 
> > 
> > <snip> 
> >> After spending two days some years ago I discovered that IE and Firefox 
> >> differed in their handling of comparisons of numerical and string data, 
> >> and that something like 
> >> 
> >> if('1'== 1) 
> >> 
> >> was handled differently in each browser. 
> >> 
> >> As with all loosely typed languages, bugs in your code are trumped by 
> >> bugs in the language itself. 
> > 
> > Was that before or after they claimed to conform to ECMA 262? If 
> > after, one or both browsers had a bug, not the language. If before, 
> > that's what you get with USPs.
> It was around 2007 give or take. IE6 and XP was current. I coded for 
> firefox, it broke in IE6. 
> 
> I actually checked the language spec. As far as I cam remember the spec 
> was explicit, that you converted to whatever the target of an 
> assignement was in a mixed type operation, but in a conditional there 
> was no assignment type...
> > 
> > <snip> 
> >> In assembler, there is only one possible meaning for each machine 
> >> instruction. Any bugs are in your code, not in the language (though they 
> >> might be in the hardware itself). 
> > 
> > Have you ever tried to understand what Edit And Mark does, and how to 
> > make use of it? 
> > 
> > 
> >> The essentially unstructured nature of the code itself *forces* you to 
> >> adopt a disciplined structured well commented approach if you are to 
> >> have a hope in hell of maintaining it. 
> > 
> > By golly, what a lot of optimism.
> Well sure, there si a lot of unstructrured muck out there, thgat is 
> unmaintainable. 
> #
> > 
> > 
> > <snip> 
> >> Local variables - a wonderful invention in C (and other similar 
> >> languages), that were ephemeral and needed no garbage collection at all, 
> >> but opened up the possibility of stamping all over the stack with 
> >> gloriously self modifying code... 
> > 
> > It's recursion that absolutely requires a stack. It's not local 
> > variables. They only use a stack to save the program occupying so much 
> > space that the program won't load.
> That is rubbish. They use the stack because the destruction of them is 
> automatic on exit from a subroutine. Otherwise you have to compile some 
> fancy code to free up the space they use.
> > 
> > 
> >> Just reading one page from a national newspaper results in 100% CPU 
> >> usage and stuttering. Yes, it's JavaShit™... 
> > 
> > One sentence, advert, one sentence, advert, one sentence, advert, ... 
> > That's marketing. 
> >
> That JavaShit makes possible
> > 
> > <snip> 
> >> Postscript. Not a page 
> >> description language. Oh no. Postscript is a fully functioned 'I can do 
> >> everything' *programming* language 
> > <snip> 
> > 
> > Postscript is a wonderful language. It produced a graph that 
> > accurately showed the weird data rate vs block length of a mag tape 
> > drive that didn't have a big enough data buffer.
> I guess thats something we all do every day.
> > 
> > 
> > <snip> 
> >> HTML was a wonderfully clear and simple language for the web. 
> >> Until bored computer scientists invented 'active pages' 
> > 
> > Until marketing demanded 'engaging' web pages. 
> >
> Ah the old Microsoft paradigm 
> "Designed to sell, but not to work"
> > 
> > <snip> 
> >> What you don't see is intelligent programmers that understand the tools 
> >> they have , what hardware is and how it works, and what the human 
> >> problem they are trying to solve actually consists of. 
> > 
> > After 20 years, some web sites allow you to write a credit card number 
> > the way it's written on the card - a space every 4 digits - so it's 
> > easy to check. But it's still a minority. <End of mini-rant>
> Precisely. 
> 
> Programs that ask you what country you are in and then will not let you 
> proceed without entering a USA specific zip code... 
> 
> ...that will not let you enter anything but alpha in a name field, and 
> then barf because the hyphenated name on your credit card is not matched 
> by what you typed in.... 
> 
> 
> > <snip> 
> > 
> > John 
> > 
> 
> 
> -- 
> New Socialism consists essentially in being seen to have your heart in 
> the right place whilst your head is in the clouds and your hand is in 
> someone else's pocket.
So anyone would like to make a qualified guess, i can't because my knowledge about the language, and even the recursive backend calling itself is very poor.
Press "play"
https://jonasth.github.io/

[toc] | [prev] | [next] | [standalone]


#39881

FromJohn G Harris <niam@jghnorth.org.uk.invalid>
Date2021-04-10 12:05 +0100
Message-ID<ph137gpihsl188mifpgu4fb9p1he5p7m9k@4ax.com>
In reply to#39878
On Sat, 10 Apr 2021 03:37:06 +0100, The Natural Philosopher
<tnp@invalid.invalid> wrote:

>On 09/04/2021 20:01, John G Harris wrote:
>> On Fri, 9 Apr 2021 10:03:13 +0100, The Natural Philosopher
>> <tnp@invalid.invalid> wrote:

  <snip>
>>> Local variables - a wonderful invention in C (and other similar
>>> languages), that were ephemeral and needed no garbage collection at all,
>>> but opened up the possibility of stamping all over the stack with
>>> gloriously self modifying code...
>> 
>> It's recursion that absolutely requires a stack. It's not local
>> variables. They only use a stack to save the program occupying so much
>> space that the program won't load.
>
>That is rubbish. They use the stack because the destruction of them is 
>automatic on exit from a subroutine. Otherwise you have to compile some 
>fancy code to free up the space they use.

You obviously haven't got the imagination needed to design new
products.

The compiler could allocate space for that local variable only. The
space doesn't need freeing because the compiler refuses to allocate it
for use by anything else.

And there *have* been compilers like that for CPUs where implementing
a stack is not practical and recursion is not essential.


  <snip>
>...that will not let you enter anything but alpha in a name field, and 
>then barf because the hyphenated name on your credit card is not matched 
>by what you typed in....

What would it do with the Malaysian whose complete full name is A ?

And Readers Digest said that someone in the USA named his daughter 5/8
Smith, just to be different.

  John

[toc] | [prev] | [next] | [standalone]


Page 1 of 4  [1] 2 3 4  Next page →

Back to top | Article view | comp.lang.javascript


csiph-web