HNHacker News
TopNewBestAskShowJobs

ayosec

42 karma · joined August 29, 2011

submissionscomments
ayosec··on Pastel: A command-line tool to generate, analyze, convert and manipulate colors
I made a wrapper to support this: https://gist.github.com/ayosec/816ccba7a75aba5336db0fe0b9791...
ayosec··on Banned C standard library functions in Git source code
https://github.com/antirez/sds
ayosec··on Firefox Local Files Theft – Not Patched Yet
Apparently not. You can create a test.html file with the following content:

    <script>
      fetch(".").then(r => console.log(r));
      fetch("/").then(r => console.log(r));
    </script>
The console show errors when these URLs are loaded:

    TypeError: NetworkError when attempting to fetch resource. test.html:2:1
ayosec··on Modern C++ Won't Save Us
How is that different to this?

    if (my_pointer != NULL)
        do_stuff(*my_pointer)
ayosec··on A surprisingly arcane little Unix shell pipeline example
sponge[1] is very useful in this scenario. The output file is written only when the `thing | thing | thing` finishes successfully.

[1]: https://linux.die.net/man/1/sponge

ayosec··on GDPR Version of USA Today Is 500KB Instead of 5.2MB
> I'd be willing to bet your "small number" of white listed websites is actually a lot more than you think. Turning off Javascript breaks a ton of sites, IME.

My experience is the opposite.

I used NoScript for almost 8 years, and then switched to uMatrix one year ago.

I don't need to enable JavaScript in most sites. And, if I need it, only enable some parts of the page. Most websites are much faster with this.

ayosec··on Run JavaScript on Cloudflare with Workers
> It's a new stand-alone HTTP server.

Are you going to publish more info about that HTTP server? Like the technology used to write it.

ayosec··on Why I Don't Like Golang (2016)
> Even serde has `#[serde(rename = "name")]` for this purpose.

You can use `#[serde(rename_all = "camelCase")]`[1] in the struct to apply the fix to all fields.

[1]: https://serde.rs/container-attrs.html#serderenameall--

ayosec··on Demangling C++ Symbols in Rust
Out of curiosity, what version of c++filt are you using?

I tried with 2.27.51 (Debian), and it works:

    mozilla::EnableIf<mozilla::IsSame<decltype ((((JS::GCVector<jsid, 0ul, js::TempAllocPolicy>*)((decltype(nullptr))0))->begin)()), decltype ((((JS::GCVector<jsid, 0ul, js::TempAllocPolicy>*)((decltype(nullptr))0))->end)())>::value, void>::Type js::CompartmentChecker::check<JS::GCVector<jsid, 0ul, js::TempAllocPolicy> >(JS::GCVector<jsid, 0ul, js::TempAllocPolicy> const&)
ayosec··on Python moved to GitHub
> Why do mobile browsers not provide the option to disable this bug?

In Firefox, you can set browser.ui.zoom.force-user-scalable to true.

Unfortunately, if have JavaScript enabled, some pages are still able to disable the zoom.

ayosec··on Rust vs C Pitfalls
> No, the default integer is u32

Maybe I'm missing something, but it seems to be i32: https://play.rust-lang.org/?gist=c79d4afef7fa20c81ba14de61f5...

ayosec··on Five years of Scala and counting: debunking some myths
> Man, using Perl professionally (as have I). What kind of job was it?

Ten years ago I was using Perl to write web applications with HTML::Mason, in a consulting firm. I can't say I miss that :-).

ayosec··on Kemal: Fast, Simple Web Framework for Crystal
What's the difference between Kemal and https://github.com/manastech/frank ?
ayosec··on The 1,000-Year GIF
12G, according to a [1]picture in the post

1. http://hyperallergic.com/wp-content/uploads/2015/09/ASLAP-on...

ayosec··on Bram Moolenaar responds to Neovim
This reminds me to the origin of Inkscape, as a fork from Sodipodi. The (only) Sodipodi committer didn't want too many patches, and he wanted to stay with C (no C++ code).

Some people forked Sodipodi, and created Inkscape. I can remember that one of their first tasks was to make the code compatible with a C++ compiler.

Nowadays, Inkscape is a very good tool, and I hope that Neovim has a great success too.

ayosec··on Choosing Scala
> being able to fire up FSC outside of IntelliJ and have your code recompile very, very quickly when you make changes

I guess that you can achieve the same benefits with an always-open SBT console.

I usually do

  ~ test
So SBT will recompile and launch test after every :w in VIM
ayosec··on Rust 0.8 released
Actually, stuff like the headers and so on, are integrated in the parser, so it generates specific types while data is arrived.

For example, https://github.com/spray/spray/blob/master/spray-http/src/ma...

ayosec··on Docker - the Linux container runtime
github: ayosec
ayosec··on A C implementation of a Sass compiler
> I hope this'll save a few hundred milliseconds every time I hit `:w`.

“few hundred milliseconds”? In a project where I'm working, our SCSS files take almost 10 seconds to recompile after every little change.

Maybe this new compiler will make the development less painful.

ayosec··on LLInt: new JS interpreter in webkit with 2-2.5x speedup
So, this means that Google will abandon V8? Or Chrome will continue with it?
ayosec··on Play on Heroku
Play! with Mirah can be a very nice combination.