HNHacker News
TopNewBestAskShowJobs

zwetan

322 karma · joined April 12, 2010

submissionscomments
zwetan··on FastCGI – The Forgotten Treasure (2002)
see https://github.com/FastCGI-Archives

where you will be able to find FastCGI Developer's Kit sources and documentations

zwetan··on The Beauty of Unix Pipelines
see here: https://pubs.opengroup.org/onlinepubs/9699919799/functions/e...

plenty of basic examples with execv, execve, execvp, etc.

if the execv() call succeed then it completely replaces the program running in the process that calls it

you can do plenty of tricks with that ;)

zwetan··on Building binary deb packages: a practical guide
what if you need to distribute a .deb containing binaries that target other operating system ?

example: I got a tool that allow from any Windows/macOS/Linux to package a runtime+script to any Windows/macOS/Linux

the Windows .exe can not be compiled from sources under Linux, so this particular runtime can never be distributed on Debian official?

zwetan··on Rethinking of CGI as a selfhosted lambda server
moving from CGi to FastCGI is pretty easy
zwetan··on ECMAScript 4: The Missing Version
You can find a copy of the PDF here

https://discuss.as3lang.org/t/javascript-the-first-20-years/...

zwetan··on ECMAScript 4: The Missing Version
In Java you would use packages to group together class definitions

same as with C++, C# where you would use namespaces to do that

aka define the scope of classes

in AS3, the packages are used the same, group collection of definitions, not only classes and interfaces but also variables, constants.

The namespaces in AS3 are used to define the visibility of definitions at the class level, a bit like being able to define your own "public" attribute.

In ActionScript 3, by default the AS3 namespace is open, for example with a builtin like Array instead of using the push() method defined in the prototype, it uses the push() method defined in the AS3 namespace.

See https://github.com/adobe/avmplus/blob/master/core/Array.as#L...

But you also have mode to compile with -ES to not open that AS3 namespace by default.

In ES4, namespaces could do more advanced stuff like namespace shadowing (only a proposal at the time), see https://web.archive.org/web/20070629024201/http://developer....

For AS3, see 1.9 Namespaces / 12 Namespaces / etc. https://github.com/as3lang/ActionScript3/wiki/Specification

zwetan··on ECMAScript 4: The Missing Version
> The closest thing we had for ES4, was probably Flash Actionscript 3.

No.

Flash = a browser plugin

ActionScript 3 = a programming language

ActionScript 3 can run in other runtimes than just Flash

Adobe AIR is another runtime, target desktop (Windows, macOS) and mobile (iOS, Android).

Redtamarin is yet another runtime (based on the avmplus) target the command-line and server-side (Windows, macOS, Linux).

zwetan··on ECMAScript 4: The Missing Version
And yet a good part of ES4 been realistically implemented in ActionScript 3 and used by many developers for over a decade.

And those namespaces in AS3 (much simpler than in ES4) I think are quite a good idea, they allow to control what is visible or not and/or to switch which implementation you use.

For example when some AS3 builtins do not support some methods defined later in ES5.1 then ES6 etc.

    ES5 function trim():String
    ES6 function repeat(count:Number):String
So yeah you not gonna use namespaces everyday for everything, but they do have allow to solve specific problems while "programming in the large".
zwetan··on Nitrome to convert its Flash game library to HTML5
no, I'm talking about this

[0] does support for socket(udp and tcp)? [1] encountered with problem when Porting UDP socket communication c code using emscripten

one example among other, and so you can use WebAssembly all you want you will never be able to implement flash.net.DatagramSocket

[0]: https://github.com/WebAssembly/design/issues/1251 [1]: https://github.com/emscripten-core/emscripten/issues/5196

zwetan··on Nitrome to convert its Flash game library to HTML5
WebAssembly not gonna give you access to syscall that are simply not there in the Web API
zwetan··on Stealing secrets from developers using WebSockets
well that very same attack vector aka "visiting a web site" is what everyone had against Flash

how convenient to consider that "pretty slim" now

zwetan··on Write Cross-Platform GUI in Swift Like It Is 1998
cross-platform but not Windows

anyone checked desktop OS market share [0] recently ?

Windows is 77.1%

[0]: https://gs.statcounter.com/os-market-share/desktop/worldwide

zwetan··on Ask HN: Do you monitor your REST APIs?
Yep, I use Google Analytics

server-side you can track using the measurement protocol

few years ago I did a prototype test with PHP, example here https://pastebin.com/PQCRcJXq

with something like Slim PHP you can add a middleware and automatically track everything, but you can also customize on a needed basis

I use the same logic with different PL on different backends etc.

for a starter it is cheap to implement and put in place, and cover almost everything

zwetan··on Opera GX – Gaming Browser
Does it support Flash ?
zwetan··on Clear Your Terminal in Style
ahhh missing a great effect

https://github.com/bartobri/no-more-secrets

zwetan··on Reasons Why Job Seekers Are Not Given Feedback
it is a two way street

I can imagine some candidates reusing half of those arguments ("Too Much Data", "Stalling For Time", etc.) to ghost recruiters and not answering to offers

someone should definitively write a counterpart "The Real Reasons Why Job Seekers Are Not Giving You Feedback"

zwetan··on Founder came back after 8 years to rewrite Flash photo editor in Canvas/WebGL
Out of curiosity, did you or other owners considered publishing the app as desktop app ?

with Adobe AIR for ex

zwetan··on Do we need a web API?
one word: security
zwetan··on Ask HN: Best language to share code between an Android and iOS app?
yep really

I know it, few other dev know it too, and the rest well...

they will keep spewing stupid stuff about how flash is dead and ignore that wonderful tech

their loss

zwetan··on Ask HN: Best language to share code between an Android and iOS app?
ActionScript 3.0

with the Adobe AIR runtime you will be able to publish to iOS, Android, Windows and macOS, see "Adobe AIR" [0]

ActionScript is something similar to TypeScript

you will have access to the whole Flash stack and more, see "Building Adobe AIR Applications" [1]

with ActionScript Native Extension (ANE) you will be able to add your native code with an easy to use AS3 interface, see "Extending Adobe AIR" [2] and "Using native extensions for Adobe AIR" [3]

Note, the latest Adobe AIR SDK are now maintained by Harman [4]

[0] https://www.adobe.com/products/air.html

[1] https://help.adobe.com/en_US/air/build/index.html

[2] https://www.adobe.com/devnet/air/articles/extending-air.html

[3] https://help.adobe.com/en_US/air/build/WS597e5dadb9cc1e0253f...

[4] https://airsdk.harman.com/

zwetan··on Dear Stack Exchange, Inc.
but if you "cut them a little slack" then there is only overflow left

that's why it explodes

zwetan··on Using ‘switch’ to match arbitrary logic instead of string or number literals
good case for replace switch with polymorphism
zwetan··on The not so hidden cost of sharing code between iOS and Android
/your/you're/

and I think you meant masochist

zwetan··on The not so hidden cost of sharing code between iOS and Android
Indeed ActionScript is a pretty decent language to work with

imagine if you could write command-line tools and server-side apps with it, that would be the dream

zwetan··on The not so hidden cost of sharing code between iOS and Android
Apache Royale is not the same thing it allows to compile ActionScript to JavaScript and so publish for the web

Adobe AIR is a compiler and a runtime

for iOS it compile AOT, for other platforms: Android, Windows, macOS, (and Linux) it compile JIT

the runtimes share the AVM2 (ActionScript Virtual Machine) and the Flash Platform API, which allow to share a lot between platforms

zwetan··on The not so hidden cost of sharing code between iOS and Android
another code-sharing solution that everyone enjoy to ignore is Adobe AIR

in 2013, AIR was v3.6, now in 2019, AIR is v33.0

not only you share code via ActionScript 3 (something like TypeScript just available 10+ years ago)

but you can also develop ActionScript Native Extension (ANE) in C, C++, Objective-C, Java, C#, Swift, etc.

and it does not only publish to mobile it also publish to desktop

but that's OK, keep ignoring it

zwetan··on Electron 6.0
there is also ActionScript 3 with Adobe AIR
zwetan··on The C standard library function atexit is broken
it should definitively clean up the module

you could make the same argument with threads

main process vs child threads, you would expect atexit installed in the child thread to execute before the main process atexit installed functions

zwetan··on The Future of Adobe Air
why the past tense?

Adobe AIR does not end, HARAMN take over its development

and AS3 is still a fine language, you can even use it on the command-line and server-side

zwetan··on I got tired of PHP and Perl, so I tried bash
How about PHP 6? not a fiasco?
Page 1 of 7Next →