Camilo

Results 103 comments of Camilo

Yes I think Reflection is useful :) That way Wren could have private methods I guess. ```js var reflector = Reflection.new('Foo') var foo = reflector.instance() var hello = reflector.method('hello') var...

Maybe can be similar to hex. - `0k512` Otherwise if more modular is needed I think adding more methods to the [Num class](https://wren.io/modules/core/num.html) would do for these constants.

Maybe ```wren // A class named constants inside Num. Num.constants.kilobyte // With static methods with common values such as 1024 Num.constants.kilobyte(512) // A static method with one parameter that will...

that reminds me more or less to pipes. (0..42) `|>` ToList In my POC here https://github.com/wren-lang/wren/pull/944 I overloaded the operator in classes. Maybe here would be an operator only for...

Thanks for sharing. I quite do not understand the usecase for reverse pipeline, but it's ok I guess for completeness?. Using `@>` seems odd choice to me. Maybe `||>`? I...

If a pipe operator is added `|>` just as a syntax sugar to `function.call()` I totally support the idea. ```wren var Kilobyte = Fn.new{|n| n * 1024} var Print =...

I will link to the Pipe proposal for JS https://github.com/tc39/proposal-pipeline-operator > The pipe operator attempts to marry the convenience and ease of method chaining with the wide applicability of expression...

> I don't think it would be a good idea to have something like this built into the language (or even the standard library) partly because of the confusion over...

I think a pipeline would work best if the `accumulator` is the first param. The `accumulator` is just the return of the previous operation that is passed down the pipeline....

> Also thinking a little further, if everything after the first element in the pipeline was guaranteed to be a function, we could perhaps dispense with Fn.new and the example...