-
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.
feat: change segment separator to empty lines only
- Loading branch information
1 parent
6fd2325
commit 21aadce
Showing
13 changed files
with
52 additions
and
65 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,9 @@ | ||
# Changelog | ||
|
||
## 0.139.0 | ||
|
||
- Change segment separator to empty lines only. | ||
|
||
## 0.138.1 | ||
|
||
- Fix end of line processing. | ||
|
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
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
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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
import { NewlineParser } from '../block'; | ||
import { union, some } from '../../combinator'; | ||
import { blankline } from '../source'; | ||
import { emptyline } from '../source'; | ||
|
||
export const newline: NewlineParser = some(union([blankline])); | ||
export const newline: NewlineParser = some(union([emptyline])); |
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
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
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
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 |
---|---|---|
@@ -1,9 +1,6 @@ | ||
import { AnyLineParser, EmptyLineParser, BlankLineParser, ContentLineParser } from '../source'; | ||
import { AnyLineParser, EmptyLineParser, ContentLineParser } from '../source'; | ||
import { line } from '../../combinator'; | ||
|
||
export const anyline: AnyLineParser = line(() => [[], ''], false); | ||
export const emptyline: EmptyLineParser = line(s => s.trim() === '' ? [[], ''] : undefined, false); | ||
|
||
const invisible = /^(?:\\?\s)*\\?$/; | ||
export const blankline: BlankLineParser = line(s => invisible.test(s) ? [[], ''] : undefined, false); | ||
export const contentline: ContentLineParser = line(s => !invisible.test(s) ? [[], ''] : undefined, false); | ||
export const contentline: ContentLineParser = line(s => s.trim() !== '' ? [[], ''] : undefined, false); |