unisonweb / unisonweb/website

Docs typo - tried to fix and failed

Open
#28 4 comments 0 reactions 2 assignees View on GitHub

@drshade is already working on this.

Since Mar 22, 2022.

documentation
Dominant language
CSS
Stars
13
Forks
8
PR merge metrics
No merged PRs in 30d

Description

Hello Unison Team!

I was trying to fix a typo I found while going through the "learn/fundamentals/control-flow/pattern-matching2" examples - specifically the slayHydra functions under the as-patterns section. Opening the website above you can see the docs are not correct, and the second slayHydra does not use the "@" symbol. So I thought I would try to fix it myself - and managed to pull and fork the docs:

$ ucm --codebase-create codebase
[Snip]
.> pull https://github.com/unisonweb/website:.learn ._learn
[Snip]
.> cd _learn.fundamentals.controlFlow
._learn.fundamentals.controlFlow> display _asPatterns
[Shows the bug! slayHydra is incorrect in the second form]
._learn.fundamentals.controlFlow> edit _asPatterns
[Shows slayHydra is correct in the second form...]

So that seems odd to me - I thought maybe initially it as Unison being clever and maybe both functions are identical so they effectively hash to the same content, so I tried to modify the second example more invasively by adding an extra function parameter to slayHydra - but to no avail. It does not seem to update (e.g. view _asPatterns vs. display _asPatterns).

Even more weird is when I go display patternMatching2 the code examples under the "As-patterns" actually show the placeSetting functions instead of the slayHydra functions!! So now I'm convinced there is a bug somewhere - but will need some guidance around this as it seems quite core and probably out of my weight class for now!

All the best,
Tom

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.