diff options
| author | Nick Pope <nick@nickpope.me.uk> | 2021-04-29 19:29:08 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-04-29 20:29:08 +0200 |
| commit | 2161db0792f2e4d3deef3e09cd72f7a08340cafe (patch) | |
| tree | 94ffd28dc91c0c7b3aae5cc53a8f1233a7b277c1 /django/utils | |
| parent | 907d3a7ff4e12ad4ccc86af26a728007fe4d6fa2 (diff) | |
Fixed capitalization of "ECMAScript" and "JavaScript".
Diffstat (limited to 'django/utils')
| -rw-r--r-- | django/utils/jslex.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/django/utils/jslex.py b/django/utils/jslex.py index 1e3a8eb532..d775d23a35 100644 --- a/django/utils/jslex.py +++ b/django/utils/jslex.py @@ -1,4 +1,4 @@ -"""JsLex: a lexer for Javascript""" +"""JsLex: a lexer for JavaScript""" # Originally from https://bitbucket.org/ned/jslex import re @@ -75,23 +75,23 @@ class Lexer: class JsLexer(Lexer): """ - A Javascript lexer + A JavaScript lexer >>> lexer = JsLexer() >>> list(lexer.lex("a = 1")) [('id', 'a'), ('ws', ' '), ('punct', '='), ('ws', ' '), ('dnum', '1')] - This doesn't properly handle non-ASCII characters in the Javascript source. + This doesn't properly handle non-ASCII characters in the JavaScript source. """ # Because these tokens are matched as alternatives in a regex, longer # possibilities must appear in the list before shorter ones, for example, # '>>' before '>'. # - # Note that we don't have to detect malformed Javascript, only properly - # lex correct Javascript, so much of this is simplified. + # Note that we don't have to detect malformed JavaScript, only properly + # lex correct JavaScript, so much of this is simplified. - # Details of Javascript lexical structure are taken from + # Details of JavaScript lexical structure are taken from # http://www.ecma-international.org/publications/files/ECMA-ST/ECMA-262.pdf # A useful explanation of automatic semicolon insertion is at @@ -184,7 +184,7 @@ class JsLexer(Lexer): def prepare_js_for_gettext(js): """ - Convert the Javascript source `js` into something resembling C for + Convert the JavaScript source `js` into something resembling C for xgettext. What actually happens is that all the regex literals are replaced with |
