Skip to content

Commit b09a623

Browse files
committed
Move FluentParserStream to src/stream.js
1 parent e9a61ec commit b09a623

File tree

3 files changed

+329
-324
lines changed

3 files changed

+329
-324
lines changed

fluent-syntax/src/ftlstream.js

Lines changed: 0 additions & 321 deletions
This file was deleted.

fluent-syntax/src/parser.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/* eslint no-magic-numbers: [0] */
22

33
import * as AST from "./ast";
4-
import { FTLParserStream } from "./ftlstream";
4+
import { FluentParserStream } from "./stream";
55
import { ParseError } from "./errors";
66

77

@@ -50,7 +50,7 @@ export default class FluentParser {
5050
}
5151

5252
parse(source) {
53-
const ps = new FTLParserStream(source.replace(/\r\n/g, "\n"));
53+
const ps = new FluentParserStream(source);
5454
ps.skipBlankBlock();
5555

5656
const entries = [];
@@ -107,7 +107,7 @@ export default class FluentParser {
107107
* themselves, in which case Junk for the invalid comment is returned.
108108
*/
109109
parseEntry(source) {
110-
const ps = new FTLParserStream(source.replace(/\r\n/g, "\n"));
110+
const ps = new FluentParserStream(source);
111111
ps.skipBlankBlock();
112112

113113
while (ps.currentChar === "#") {

0 commit comments

Comments
 (0)