From 86db4f4201627eedd8ad8c4f8f6cd0934161e5c7 Mon Sep 17 00:00:00 2001 From: Katrin Leinweber Date: Wed, 25 Jun 2025 19:04:25 +0200 Subject: [PATCH] Correct a few spelling mistakes in docs --- README.md | 4 ++-- docs/experiments.md | 4 ++-- docs/ideas.md | 2 +- docs/shortcuts.md | 4 ++-- docs/similarity_tutorial.md | 4 ++-- docs/syntax.md | 4 ++-- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index 4c35c6d..cf65156 100644 --- a/README.md +++ b/README.md @@ -57,7 +57,7 @@ For example, let's take an `Integer` in Ruby: 1 ``` -It's corresponding s-expression would be: +Its corresponding s-expression would be: ```ruby s(:int, 1) @@ -198,7 +198,7 @@ def my_method end ``` -It's corresponding s-expression would be: +Its corresponding s-expression would be: ```ruby ast = diff --git a/docs/experiments.md b/docs/experiments.md index 80985eb..a3a88b7 100644 --- a/docs/experiments.md +++ b/docs/experiments.md @@ -130,8 +130,8 @@ line tool. - And the `policy` is executed to check if the current change is valuable If the file contains multiple `before` or `after` blocks, each removal will -occur independently and the successfull removals will be combined as a -secondary change. The process repeates until find all possible combinations. +occur independently and the successful removals will be combined as a +secondary change. The process repeats until find all possible combinations. See more examples in [experiments](experiments) folder. diff --git a/docs/ideas.md b/docs/ideas.md index 2939d78..6f6739c 100644 --- a/docs/ideas.md +++ b/docs/ideas.md @@ -41,7 +41,7 @@ This example, shows adds and removals from specific node targets between two different files. If we start tracking AST transition synapses and associating with "Fixes" or -"Reverts" we can predict introduction of new bugs by inpecting if the +"Reverts" we can predict introduction of new bugs by inspecting whether the introduction of new patterns that can be possibly reverted or improved. ## Fast Rewriter with pure strings diff --git a/docs/shortcuts.md b/docs/shortcuts.md index 867ed62..b95e33e 100644 --- a/docs/shortcuts.md +++ b/docs/shortcuts.md @@ -13,7 +13,7 @@ several interesting cases in action. ## List your fast shortcuts -As the interface is very rudimentar, let's build a shortcut to print what +As the interface is very rudimentary, let's build a shortcut to print what shortcuts are available. This is a good one to your `$HOME/Fastfile`: ```ruby @@ -46,7 +46,7 @@ I always miss bringing something simple as `grep keyword` where I can leave a si search in all types of nodes and report interesting things about it. Let's consider a very flexible search that can target any code related to some -keyword. Considering that we're talking about code indentifiers: +keyword. Considering that we're talking about code identifiers: ```ruby diff --git a/docs/similarity_tutorial.md b/docs/similarity_tutorial.md index abbf91f..3bb6b07 100644 --- a/docs/similarity_tutorial.md +++ b/docs/similarity_tutorial.md @@ -76,14 +76,14 @@ Fast.search_file('(class (const nil $_))','lib/fast.rb').grep(Symbol) :ExperimentFile] ``` -The idea of this inspecton is build a proof of concept to show the similarity +The idea of this inspection is building a proof of concept to show the similarity of matcher classes because they only define a `match?` method. ```ruby patterns = Fast.search_file('class','lib/fast.rb').map{|n|Fast.expression_from(n)} ``` -A simple comparison between the patterns size versus `.uniq.size` can proof if +A simple comparison between the patterns size versus `.uniq.size` can prove that the idea will work. ```ruby diff --git a/docs/syntax.md b/docs/syntax.md index 83b2005..dd8d390 100644 --- a/docs/syntax.md +++ b/docs/syntax.md @@ -192,7 +192,7 @@ def duplicate(value) end ``` -The expression is matching nodes that have a integer granchild and also with +The expression is matching nodes that have an integer grandchild and also with type `def`. ## `...` is a **node** with children @@ -305,7 +305,7 @@ Double check the expressions that have matched printing the AST: ## `{}` is for **any** matches like **union** conditions with **or** operator -Let's say we to add check all occurrencies of the constant `ANSWER`. +Let's say we want to add check all occurrences of the constant `ANSWER`. We'll need to get both `casgn` and `const` node types. For such cases we can surround the expressions with `{}` and it will return if the node matches with