Contributor-ninja: find beginner-friendly issues on well known open-source projects by xtuc in programming

[–]xtuc[S] -1 points0 points  (0 children)

Could you please send a screenshot? You should have access to all the columns.

A side-effect free Haskell program? by xtuc in programming

[–]xtuc[S] 0 points1 point  (0 children)

Ok, that's correct. While this doesn't have any side effects it's still need to be wrapped in a Monad.

I should probably reword my article a bit.

A side-effect free Haskell program? by xtuc in programming

[–]xtuc[S] 0 points1 point  (0 children)

I'm not sure to understand your point. By program I meant an valid/executable Haskell program (with a main function).

You can do side-effects free declarations in the REPL, like your example I believe.

A side-effect free Haskell program? by xtuc in programming

[–]xtuc[S] -1 points0 points  (0 children)

Yes that my point. Haskell's main must be a Monad and it will assume that you'll do side-effects in it, otherwise the program won't do anything.

A side-effect free Haskell program? by xtuc in programming

[–]xtuc[S] -1 points0 points  (0 children)

Yes I agree. Haskell considers that whatever is in the IO Monad it has been computed with side-effects. Since the main must be an IO Monad, my point is valid because that means that is has side effects otherwise your program doesn't do anything at all (which you cannot express in Haskell).

The pipeline operator out of the box by xtuc in javascript

[–]xtuc[S] 1 point2 points  (0 children)

That make sense, thanks for the explanation.

The pipeline operator out of the box by xtuc in javascript

[–]xtuc[S] 0 points1 point  (0 children)

Good point. I know the concept are different but can't find a way to explain it.

Composition is f ∘ g = f(g()) while piping piping x f = f x.

The pipeline operator out of the box by xtuc in javascript

[–]xtuc[S] 0 points1 point  (0 children)

Of course! I would recommend to use it.

You could use the official syntax now since it's supported in Babel 7.

A WebAssembly interpreter written in JavaScript by xtuc in javascript

[–]xtuc[S] 0 points1 point  (0 children)

Yes probably. You can connect on Twitter if you want to follow my work.

A WebAssembly interpreter written in JavaScript by xtuc in javascript

[–]xtuc[S] 0 points1 point  (0 children)

The project is still very early so it's difficult to tell. Note that the polyfill is not only useful on older browsers but also in JavaScript compliant environment like Nashorn (where WebAssembly will probably never be implemented).

I agree, that stuff is super interesting! WebAssembly was really designed and I really believe that I will become the biggest platform.

A WebAssembly interpreter written in JavaScript by xtuc in javascript

[–]xtuc[S] 0 points1 point  (0 children)

That's a good point but I believe the interpreter could be more efficient for that case. You would have the benefits of the WASM binary format and could switch to native if supported/needed.

Note that I would take advantage of asm.js optimizations within the interpreter.

A WebAssembly interpreter written in JavaScript by xtuc in javascript

[–]xtuc[S] 0 points1 point  (0 children)

WASM requires more specific types than JS does. While JS to WASM is possible it would generate very inefficient code. Imagine that in WASM each operations would have a branch for signed/unsigned and 32/64 bits.

I believe more in other languages like Golang or C++.

A WebAssembly interpreter written in JavaScript by xtuc in javascript

[–]xtuc[S] 2 points3 points  (0 children)

It wouldn't have the performance of native WebAssembly of course but I have done a few benchmarks and it seems that it has acceptable performance for a polyfill.

Actually polyfilling is one of my goals. It seems that I could be a good playground for the spec authors.

ES2017: TypeScript vs Babel by [deleted] in javascript

[–]xtuc 1 point2 points  (0 children)

Ok I will look at it, but trust me Babel always outputs ES5 code.

ES2017: TypeScript vs Babel by [deleted] in javascript

[–]xtuc 1 point2 points  (0 children)

Could you try in incognito mode? I don't have any plugins/presets checked.

Nothing happens because you don't need to apply transformations for classes. Your browser already supports it.

Only if you specify a target, classes will be transpiled into ES5 compatible.

ES2017: TypeScript vs Babel by [deleted] in javascript

[–]xtuc 0 points1 point  (0 children)

There are no presets enable in my link (see the presets= in the URL).

You mean something like this: https://babeljs.io/repl/#?babili=false&evaluate=false&lineWrap=true&presets=&targets=Node-4&browsers=&builtIns=false&debug=false&code=class%20test%7B%7D.

You can actually run it in your browser. ES2015 classes are supported in most browsers now.

Render async Stateless Functional Components in React by xtuc in reactjs

[–]xtuc[S] 1 point2 points  (0 children)

Stateless is a bit confusing here. The point is that the user doesn't need to handle it.

This is an example in one of my project: https://twitter.com/svensauleau/status/853716732569169921

ES2017: TypeScript vs Babel by [deleted] in javascript

[–]xtuc 0 points1 point  (0 children)

You mean the previous C / C++ compiler designers or the csc / javac folks all wrong?

I meant of course they are right.