Page MenuHomePhabricator

Fix bugs in python lexer
ClosedPublic

Authored by sophiebits on Jun 6 2014, 12:23 AM.
Tags
None
Referenced Files
Unknown Object (File)
Jun 9 2025, 2:22 AM
Unknown Object (File)
May 6 2025, 11:17 PM
Unknown Object (File)
Apr 29 2025, 1:28 AM
Unknown Object (File)
Apr 25 2025, 1:18 AM
Unknown Object (File)
Apr 23 2025, 11:25 PM
Unknown Object (File)
Apr 21 2025, 2:44 PM
Unknown Object (File)
Apr 21 2025, 6:30 AM
Unknown Object (File)
Apr 20 2025, 2:07 PM
Subscribers

Details

Summary

Two things:

  • The appearance of \\ or \' or \-followed-by-a-newline in a raw string would improperly end the string
  • A disallowed newline in a string would cause an error instead of trying to continue anyway
Test Plan

Ran it on a file that was failing for me that was something like:

x = r'\\"'
# hello there

Diff Detail

Repository
rPHU libphutil
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

sophiebits retitled this revision from to Fix bugs in python lexer.
sophiebits updated this object.
sophiebits edited the test plan for this revision. (Show Details)
sophiebits added a reviewer: epriestley.
epriestley edited edge metadata.
This revision is now accepted and ready to land.Jun 6 2014, 12:25 AM
epriestley updated this revision to Diff 22445.

Closed by commit rPHU7e75bf271c66 (authored by @spicyj, committed by @epriestley).