Skip to content

Commit

Permalink
Merge pull request #1634 from ruby/update-syntax
Browse files Browse the repository at this point in the history
Update syntax.md
  • Loading branch information
soutaro committed Nov 22, 2023
2 parents 78fa36f + 9d8c10c commit f1dcf37
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions docs/syntax.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ _literal_ ::= _string-literal_
| `true`
| `false`

_proc_ ::= _parameters?_ _self-type-binding?_ _block?_ `->` _type_
_proc_ ::= `^` _parameters?_ _self-type-binding?_ _block?_ `->` _type_
```

### Class instance type
Expand Down Expand Up @@ -311,8 +311,6 @@ end
```markdown
_method-type_ ::= _parameters?_ _block?_ `->` _type_ # Method type

_proc_ ::= `^` _parameters?_ _self-type-binding?_ _block?_ `->` _type_ # Proc type

_parameters?_ ::= (Empty)
| _parameters_ (Parameters)

Expand Down Expand Up @@ -435,8 +433,8 @@ _visibility-member_ ::= _visibility_

_ivar-name_ ::= /@\w+/
_cvar-name_ ::= /@@\w+/
_method-name_ ::= ...
| /`[^`]+`/
_method-name_ ::= _most of the possible ruby method names_
| /`[^`]+`/ # Quoted method names
```

### Ivar definition
Expand Down

0 comments on commit f1dcf37

Please sign in to comment.