This repository has been archived by the owner on Sep 8, 2023. It is now read-only.
forked from rouge-ruby/rouge
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support additional number literals in the Ruby lexer (rouge-ruby#1456)
Ruby supports number literals that include `_` and that include exponents. This commit adds support for this syntax to the Ruby lexer.
- Loading branch information
Showing
2 changed files
with
8 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -84,6 +84,9 @@ end | |
|
||
# It appears in Floats | ||
2.3 | ||
1.2e3 | ||
1e23 | ||
1_2.3_4e5 | ||
|
||
# It appears in Range | ||
1..10 | ||
|