4 ms·
I count myself lucky because I don’t really know vbscript. Does legacy vb have a notion of first order functions and async?
by AzzieElbab 6y ago
I count myself lucky because I don’t really know vbscript. Does legacy vb have a notion of first order functions and async?
- skissane 6y agoNo it doesn't. But there is every reason to expect those features would have been added at some point if VBScript had been more popular. Indeed, if we look at VBScript's cousin, VB.NET, we find both first order functions and async functions, at least in its newer versions. (Keep in mind that those features weren't present in older versions of JavaScript either. Async functions were only added in ECMAScript 2016. First order functions have been there from the start, but ECMAScript 2015 greatly improved the syntax for anonymous functions with its introduction of arrow syntax.)
- BrendanEich 6y agoIn the multiverse of madness, you are welcome to the universe where we had jquery.vbs ;-).
- the_only_law 6y ago> to the universe where we had jquery.vbs ;-) I'm genuinely terrified.
- AzzieElbab 6y agoby async I did not mean syntax sugar. More like way to do async via continuations/callbacks
- skissane 6y agoIf all you mean by "async" is callbacks, then VBScript already has those. In VBScript that runs under Windows Script Host, callbacks are implemented using the WScript.ConnectObject method. (I'm not sure about VBScript running under IE or classic ASP, if they could use the same method or had to use a different one. But anyway, if VBScript can do it in one context but not another, that would be a deficiency they could have easily fixed if there were a demand.)