Version: 3.3.5 (using KDE 3.5.5 "release 45.2" , openSUSE 10.2) Compiler: Target: x86_64-suse-linux OS: Linux (x86_64) release 2.6.18.2-34-default Hello, Bash parser inside kdevelop (and kate) is buggy. The use o ";;" in the last case clause is optional. Parser fails to accept case without it. Ex: case 1 in 2) echo xxx; ;; 1) echo yyy; esac The use of the text "do" without '"' bugs the parser. Ex: function aaa { echo do } XXX
I can confirm the first one, but the 2nd example works here. Same as with the other the problem is in kate.
Forgot to change the status.
(Really reassing to the Kate guys.)
This bug is still valid in kde4rc2
The first issue is still valid using: Qt: 4.4.3 + qt-copy-patches-889120 KDE: 4.1.87 (KDE 4.1.87 (KDE 4.2 >= 20090101)) kdelibs svn rev. 905636 / kdebase svn rev. 905636 kdesdk svn rev. 905676 on ArchLinux x86_64 - Kernel 2.6.27.10
SVN commit 905727 by jowenn: case 1 in 2) echo xxx; ;; 1) echo yyy; esac works now for KDE 4.2 The echo do problem still exists this is a littlebit more work and needs a rewrite of the FindAll and FindCommands contexts CCBUG: 140511 M +2 -1 syntax/data/bash.xml M +9 -0 tests/highlight.sh WebSVN link: http://websvn.kde.org/?view=rev&revision=905727
Testing with kde4.3 I think that the "case" situation is not completely fixed. In Kate, if I add the ";;", esac left bar color is changed to something darker, which I suppose to identify the last line in a block. The "do" one is still open
Moving to wish list status. All highlightings works with heuristics and will never be perfect. Perhaps somebody can provide a patch, therefor not closing it.
Just the do problem persists in kde 4.8
Created attachment 70355 [details] This fixes the problem of parsing arguments as commands.
Git commit a021bc5b6e039de781628de777def492c7887f4e by Christoph Cullmann. Committed on 29/10/2012 at 05:03. Pushed by cullmann into branch 'master'. commit patch by Luiz Angelo De Luca to fix issues with bash hl M +29 -9 part/syntax/data/bash.xml http://commits.kde.org/kate/a021bc5b6e039de781628de777def492c7887f4e
This patch horribly breaks something common as this: foo="$(pwd)" the ) is apparently eaten by some other context than the SubstCommand context and thus it never pops
Hello Milian, Thanks for your report. The version 2.15 is known to have problems with ")", "}" or "`". I should have commented on this bug before about these problems. Could you please test the proposed patch at bug 311233? This is the bash.xml link: https://bugs.kde.org/attachment.cgi?id=75714