Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,9 @@ Language changes
* `=>` now has its own precedence level, giving it strictly higher precedence than
`=` and `,` ([#25391]).

* `begin` is disallowed inside indexing expressions, in order to enable the syntax
`a[begin]` (for selecting the first element) in the future ([#23354]).

* Underscores for `_italics_` and `__bold__` are now supported by the Base Markdown
parser. ([#25564])

Expand Down
2 changes: 2 additions & 0 deletions src/julia-parser.scm
Original file line number Diff line number Diff line change
Expand Up @@ -1318,6 +1318,8 @@

;; parse expressions or blocks introduced by syntactic reserved words
(define (parse-resword s word)
(if (and (eq? word 'begin) end-symbol)
(parser-depwarn s "\"begin\" inside indexing expression" ""))
(with-bindings
((expect-end-current-line (input-port-line (ts:port s))))
(with-normal-context
Expand Down