✓👍
On Thursday, January 18, 2018 at 9:09:32 AM UTC-6, Ville Hellman wrote:
>
> Hey all,
>
> I'm proposing a new option for the `mix new` task: `--nocomments` when run
> with this option it would omit all comments from the generated project
> files.
>
> When first starting with Elixir I found the
I’ve trying to create a kind of runner for a set of components, where each
component runs on a separate node, and each component is an independent
application.
I’ve stolen code from the swarm cluster tests, and I’m successfully
creating nodes which seem to contain the Elixir runtime.
As I in
On Wednesday, February 14, 2018 at 4:25:36 PM UTC-6, José Valim wrote:
>
> We also do a similar setup in firenest test suite:
> https://github.com/phoenixframework/firenest/blob/master/test/shared/test.ex
>
>
I'm trying not to use a boot loader: the assumption is that the code for
the spawned n
Oh, and just to clarify: I'm trying to do this in dev mode, so I want to
run the application from its project directory.
I may have to bit the bullet and just spawn a shell and run mix in it... :(
--
You received this message because you are subscribed to the Google Groups
"elixir-lang-core"
rocess, then indeed you might have
> better luck just running Mix via `System.cmd` - there isn't necessarily
> anything wrong with that approach, but then it's entirely up to you to
> ensure that the spawned nodes are cleaned up before shutting down the
> spawning node.
When I use IO.inspect in a pipeline, I often find myself wanting to tag the
output with some kind of label:
~~~ elixir
get_name()
|> IO.inspect()
|> lookup_score()
|> IO.inspect
~~~
so I sometimes write a trivial helper
~~~
def dump(value, label) do
IO.puts "#{label}: #{inspect value}"
valu
Damn. That was quick.
(hides head in shame)
On Monday, February 19, 2018 at 7:40:07 PM UTC-6, Paul Schoenfelder wrote:
>
> You can already do this today with IO.inspect(foo, label: "label") :)
>
> Paul
>
> On Mon, Feb 19, 2018 at 7:32 PM pragdave >
> wrot
I quite often put the API for a library in the top-level module, but
delegate all the calls down into various implementation modules.
This leaves we with the problem of where to put the @doc.
I want to put it in the API module so that clients of the library can see
all the API documentation
On Friday, May 24, 2019 at 4:18:39 PM UTC-5, Andrea Leopardi wrote:
>
> Forgot to say, I think the best route would be @doc see:
> "String.length/1". Then it's the job of the doc tool to render it if they
> want to.
>
But the _all_ doc tools would hav e to support it
--
You received thi
>
>
> Btw, “see” could be implemented as a library today, it just needs to be a
> macro (a module attribute would be weird, especially since “@attr val” is
> meant to set the attribute, and not execute custom code). So I would go
> this route!
>
It definitely could, but then we'd need `use see
I know this has been discussed before, in different forms, but I thought
I’d just have another go following my recent earth-shattering PR :)
I’d like to propose a new unary operator, &>. It works just like the
pipeline |>, but doesn’t take a left argument. Instead it returns an arity
1 functi
On Tuesday, October 25, 2022 at 9:56:14 PM UTC-5 dorga...@gmail.com wrote:
> For the plugs example, how is it better than the alternative that exists
> today?
>
Because it is written without the magic. The way Plug currently works is
needlessly nonfunctional and opaque. With this small chang
iex(16)> defmodule A do def _fib(n, %{ ^n => result }), do: result end**
(MatchError) no match of right hand side value: :error
Notice this is a compilation error.
Some background. This is part of a Fibonacci function that uses a cache
(the second parameter). If I get a cache hit, I want to r
On Thursday, February 23, 2017 at 2:05:59 AM UTC-6, José Valim wrote:
>
> It is definitely a compiler bug, as that error message is not clear what
> is happening.
>
> I will fix it on master. Thank you.
>
Does that mean I won't be able to write this?
--
You received this message because you
Let’s say I wanted to write a macro called defwombat that could be used
just like defmodule but that compiled marsupials. And let’s pretend you
thought it was a great idea.
What I’d like to be able to do is to write:
*dave.ex:*
defwombat Eric do
# ... marsupial stuffend
That is, I’d like
15 matches
Mail list logo