Haskell nested block comments parsed incorrectly
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
GtkSourceView |
Fix Released
|
Medium
|
|||
gtksourceview (Ubuntu) |
Fix Released
|
Low
|
Ubuntu Desktop Bugs |
Bug Description
Release: Ubuntu hardy (development branch) 8.04
Package: libgtksourcevie
Package version: 2.2.0-2
Haskell block comments can be nested correctly, unlike C block comments. A block comment inside another block comment should not prematurely close the outer block comment. However, GtkSourceView parses this incorrectly and treats nested comments as with C block comments, with the first closing comment marker reached closing all previously opened block comment levels, regardless of nesting depth.
Steps to reproduce:
1) Start an application using GtkSourceView, e.g. gedit
2) Set language to Haskell (haskell.lang). In gedit, View > Highlight Mode > Sources > Haskell
3) Type an opening block comment marker "{-". Text color changes to indicate a comment.
4) Type another opening block comment marker to nest a second block comment. Text color still indicates a comment.
5) Type a closing block comment marker to close the inner nested block comment.
6) Type some comment text.
7) Type another closing block comment marker to close the outer block comment.
Expected: The second closing block comment marker and the text before it should be colored to indicate a comment.
Actual: They are colored as normal text.
Changed in gtksourceview: | |
status: | Unknown → New |
Changed in gtksourceview: | |
status: | New → Fix Released |
Changed in gtksourceview: | |
importance: | Unknown → Medium |
Thanks for your bug report. This bug has been reported to the developers of the software. You can track it and make comments here: http:// bugzilla. gnome.org/ show_bug. cgi?id= 532964