GNU nano - Bugs: bug #56478, delayed syntax parsing is...
You are not allowed to post comments on this tracker with your current authentication level.
bug #56478: delayed syntax parsing is problematic for included files with multiple syntaxes
Submitter: | Benno Schulenberg <bens> | ||
Submitted: | Wed 12 Jun 2019 10:14:58 AM UTC | ||
Severity: | 3 - Normal | Status: | Fixed |
Assigned to: | bens | Open/Closed: | Closed |
Jump to the original submission
Fri 14 Jun 2019 09:21:16 AM UTC, comment #8: |
Benno Schulenberg <bens> |
Thu 13 Jun 2019 02:30:15 PM UTC, comment #7: Last version also did not report anything for two successive syntax commands in an included file. Attached is a version that handles that case too, thus reporting any empty syntax (and other rcfile errors) at startup. |
Benno Schulenberg <bens> |
Thu 13 Jun 2019 10:18:50 AM UTC, comment #6: It didn't report disallowed commands in included files any more.
|
Benno Schulenberg <bens> |
Thu 13 Jun 2019 07:11:38 AM UTC, comment #5: Looks good to me, what doesn't work? |
Brand Huntsman <brand> |
Wed 12 Jun 2019 06:11:56 PM UTC, comment #4: Here's one that mostly works. Debugging stuff still present. |
Benno Schulenberg <bens> |
Wed 12 Jun 2019 04:15:16 PM UTC, comment #3: This is what I have so far. It properly gets multiple syntaxes from an included file, but doesn't get any syntaxes any more from a main file, nor does it process any extendsyntax commands. |
Benno Schulenberg <bens> |
Wed 12 Jun 2019 03:07:19 PM UTC, comment #2: I didn't think there would be any syntax files out there that defined multiple syntaxes, but looking at the Scopatz collection https://github.com/scopatz/nanorc/, there are a few that do. :|
|
Benno Schulenberg <bens> |
Wed 12 Jun 2019 12:23:32 PM UTC, comment #1: Ah, I didn't know that was even possible. It might not be too hard to continue reading the file and ignore commands other than syntax, header and magic. When one of the syntaxes in the file is used, the normal processing of the file would load all syntaxes in that file and mark them as loaded. The only problem is that set_syntax_colorpairs() would only be called for the syntax being used, so syntaxtype would need some other way to mark syntaxes that have been loaded but colorpairs aren't initialized.
|
Brand Huntsman <brand> |
Wed 12 Jun 2019 10:14:58 AM UTC, original submission:
To reproduce, run:
|
Benno Schulenberg <bens> |
Depends on the following items: None found
Items that depend on this one: None found
There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.
Follow 10 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2019-06-14 | bens | Status | In Progress | Fixed | |
Open/Closed | Open | Closed | |||
2019-06-13 | bens | Attached File | - | Added 0001-rcfile-fully-read-each-included-file-so-all-its-synt.patch, #47085 | |
2019-06-13 | bens | Attached File | - | Added multiple-syntaxes-in-one-file--3.diff, #47083 | |
Summary | delayed syntax parsing is problematic for gentoo.nanorc | delayed syntax parsing is problematic for included files with multiple syntaxes | |||
2019-06-12 | bens | Attached File | - | Added multiple-syntaxes-in-one-file--2.diff, #47081 | |
Status | None | In Progress | |||
2019-06-12 | bens | Attached File | - | Added multiple-syntaxes-in-one-file.diff, #47080 | |
2019-06-12 | brand | Attached File | - | Added disallow-multiple-syntaxes-per-include-file.patch, #47079 | |
2019-06-12 | bens | Carbon-Copy | - | Added brand |
Powered by Savane 3.13-758e.
Corresponding source code
Fixed in git, commit 7028adf2.
And closing because unreleased.