The elm-tools/parser documentation recommends using parsing pipelines such
as
type alias Point = { x : Float, y : Float}
point : Parser Pointpoint =
succeed Point
|. symbol "("
|. spaces
|= float
|. spaces
|. symbol ","
|. spaces
|= float
|. spaces
|.
I'm a bit confused what is the intended usage of elm-tools/parser to
generate custom error messages. In particular, when creating a Parser
value, but before calling run, there's no way to specify what sorts of
errors can happen and messages to generate in response.
The only interface in the
Thanks! I assumed andThen would be involved somehow but didn't quite see
how to use it.
That said, I don't think validation is necessary during the parsing
> process. You can check it after everything is parsed. That is much simpler.
If I check everything after it is parsed, how do I know
I have found many situations in which I am forced by the compiler to deal
with a situation that will never come up at runtime (or, if it does come
up, it's a bug in my code and not something the user can do to fix). For
example, I might make a provably non-empty List (e.g., it is always made by
mon homework exercise).
Maybe it's just a matter of me thinking harder about these situations.
On Monday, August 21, 2017 at 1:41:55 PM UTC-7, Dave Doty wrote:
>
> Hi Aaron:
>
> Thanks for the ideas! I think they certainly can mitigate this concern in
> many situations.
>
>
o implement those
> defaults even though you know in reality that code path will never get
> executed.
>
> 2) You said you had a provably non-empty list, so why not make a
> NonEmptyList type to represent that instead of using List. Then you could
> make `NonEmptyList.maximum : No
onsider all the assumptions
> that references have been relying on?)
>
> On Mon, Aug 21, 2017 at 1:56 PM, Dave Doty <pex...@gmail.com
> > wrote:
>
>> Talking through this helped me formulate a better strategy for at least
>> this one problem, along the l
wing a new, more informative
exception.
On Thursday, August 3, 2017 at 12:03:34 PM UTC-7, Dave Doty wrote:
>
> I'm a bit confused what is the intended usage of elm-tools/parser to
> generate custom error messages. In particular, when creating a Parser
> value, but before calli
Is there a way in elm-community/elm-test to specify a timeout; i.e., the
test fails if the code takes longer than n seconds to execute?
--
You received this message because you are subscribed to the Google Groups "Elm
Discuss" group.
To unsubscribe from this group and stop receiving emails
is being used and then in yout subscription you have
>
> myKbdSubs model =
> if model.editorBeingUsed then
> Sub.none
> else
>
> On Thursday, 19 October 2017 00:34:35 UTC+2, Dave Doty wrote:
>
> I am using this Ace Editor adapted to Elm:
>> https://github.
10 matches
Mail list logo