dotnet / dotnet/fsharp

Improve error message in pattern matching when we forget to match the payload

Open
#4,246 2 comments 7 reactions 1 assignee Claimed by @edgarfgp View on GitHub
Area-Diagnostics Feature Improvement Theme-Simple-F#
Dominant language
F#
Stars
4.3k
Forks
876
Avg merge
4d 11h
Merged PRs (30d)
131

Description

type Msg =
| ShowImage of int

let update model (msg:Msg) =
match msg with
| ShowImage ->
model

![image](https://user-images.githubusercontent.com/57396/35276256-164039ca-0043-11e8-8f95-beaa4f99ecda.png)

this is not helpful for newcomers. We should somehow explain that the pattern needs a payload placeholder.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.