Menu

#1253 [PATCH] Critical fixes for Nim raw strings

Committed
closed
5
2019-03-07
2019-01-07
Jad Altahan
No

Upon further inspecting the Nim manual, I have discovered that raw strings aren't as simple as they seemed to be at first sight.

Nim has what it calls "generalized raw string literals", which can be anything besides r"/R".
Triple doubles can be made raw strings as well. And they also don't necessarily end in exactly 3 double quotes.

Without these fixes, string styling will become broken in affected scenarios.

1 Attachments

Discussion

  • Neil Hodgson

    Neil Hodgson - 2019-01-07

    Scintilla is currrently frozen for 4.1.3. Not really seeing this as critical as there is no hang, crash or reversion from Scintilla 4.1.2. I'll examine this next week, after the release.

     
  • Neil Hodgson

    Neil Hodgson - 2019-01-13
    • labels: nim --> nim, scintilla
     
  • Neil Hodgson

    Neil Hodgson - 2019-01-13

    Committed as [cacdbd].

    It would help if lexer fixes included examples in text format that can show the problem so that the fix can be checked. That may also benefit others looking back through history when there are regressions.

     

    Related

    Commit: [cacdbd]

  • Jad Altahan

    Jad Altahan - 2019-01-13

    Good idea! Will do next time. For this patch, the attached text file contains Nim strings written in many different ways. This is what helped me discover and fix the issues.

    The original file can be also found at https://github.com/nim-lang/nim-mode/blob/master/tests/syntax/string.nim

    Thanks.

     
  • Neil Hodgson

    Neil Hodgson - 2019-03-07
    • status: open --> closed
     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.