Skip to content
This repository has been archived by the owner on Nov 5, 2021. It is now read-only.

Commit

Permalink
Merge pull request #141 from qwefgh90/main
Browse files Browse the repository at this point in the history
improve a rule which freeze a page in restructuredText
  • Loading branch information
alexdima authored Jun 14, 2021
2 parents 19ce286 + 57a88a0 commit bb52559
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
6 changes: 6 additions & 0 deletions src/restructuredtext/restructuredtext.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@
import { testTokenization } from '../test/testRunner';

testTokenization('restructuredtext', [
[
{
line: 'some property = Text::ProxyLibrary::ProxyInterfaceTest::DeleteProxyInterface();',
tokens: [{ startIndex: 0, type: '' }]
}
],
[
{
line: '#####',
Expand Down
7 changes: 3 additions & 4 deletions src/restructuredtext/restructuredtext.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,9 @@ export const language = <languages.IMonarchLanguage>{
],

alphanumerics: /[A-Za-z0-9]/,
alphanumericsplus: /[A-Za-z0-9-_+:.]/,
simpleRefNameWithoutBq: /(?:@alphanumerics@alphanumericsplus*@alphanumerics)+|(?:@alphanumerics+)/,
simpleRefName: /(?:`@simpleRefNameWithoutBq`|@simpleRefNameWithoutBq)/,
phrase: /@simpleRefName(?:\s@simpleRefName)*/,
simpleRefNameWithoutBq: /(?:@alphanumerics[-_+:.]*@alphanumerics)+|(?:@alphanumerics+)/,
simpleRefName: /(?:`@phrase`|@simpleRefNameWithoutBq)/,
phrase: /@simpleRefNameWithoutBq(?:\s@simpleRefNameWithoutBq)*/,
citationName: /[A-Za-z][A-Za-z0-9-_.]*/,
blockLiteralStart: /(?:[!"#$%&'()*+,-./:;<=>?@\[\]^_`{|}~]|[\s])/,
precedingChars: /(?:[ -:/'"<([{])/,
Expand Down

0 comments on commit bb52559

Please sign in to comment.