View Issue Details

IDProjectCategoryView StatusLast Update
0017577LazarusIDEpublic2010-11-15 11:16
ReporterSven BarthAssigned ToMartin Friebe 
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Version0.9.29 (SVN)Product Build 
Target Version0.9.30Fixed in Version0.9.29 (SVN) 
Summary0017577: "index" and "message" are highlighted when they shouldn't be
Description"index" and "message", which are both context sensitive keywords, are highlighted in situations where they shouldn't be.

index:

type
  Index = Integer;

  TTest = class
    Index: Integer;
    property Foo[Index: Integer]: String;
    property Test: Index read Index write Index;
  end;

In "Foo" "Index" is highlighted although it shouldn't be. In property "Test" all three "Index" are highlighted (yes, that compiles ^^). This also happens in global properties.

message:

procedure Message(var Message: Message); message 23;

Only the last "message" should be highlighted (yes, that compiles if a type "Message" is defined ^^).
Also "message" is highlighted everywhere in a unit.
TagsNo tags attached.
Fixed in Revision27910, 28222
LazTarget1.0
Widgetset
Attached Files

Activities

Martin Friebe

2010-10-28 00:49

manager   ~0042225

please test with revision 27910 or up.

close if ok

Sven Barth

2010-11-14 18:43

manager   ~0043045

Last edited: 2010-11-14 18:44

Index issues are resolved.

But "message" is still highlighted outside of class declarations.

E.g.

var
  Message: Integer; // wrong in interface and implementation

type
  Message = Integer; // wrong in interface and implementation
  Bar = Message; // wrong in interface and implementation

procedure Bar;
var
  message: Integer; // wrong
begin
  message := 1; // ok
end;

It's also highlighted in interface declarations...

In short: only highlight "message" inside of class declarations (and generic declarations) if it's at the end of a "procedure" declaration.

I don't know how easy you can implement that, but that would be the ideal situation.

Edit: Revision 28200

Regards,
Sven

Martin Friebe

2010-11-14 20:48

manager   ~0043049

please test again

Sven Barth

2010-11-15 11:16

manager   ~0043061

Now I'm happy. Thank you very much :D

Regards,
Sven

Issue History

Date Modified Username Field Change
2010-10-08 21:33 Sven Barth New Issue
2010-10-08 22:19 Martin Friebe Status new => assigned
2010-10-08 22:19 Martin Friebe Assigned To => Martin Friebe
2010-10-28 00:49 Martin Friebe Fixed in Revision => 27910
2010-10-28 00:49 Martin Friebe LazTarget => 1.0
2010-10-28 00:49 Martin Friebe Status assigned => resolved
2010-10-28 00:49 Martin Friebe Fixed in Version => 0.9.29 (SVN)
2010-10-28 00:49 Martin Friebe Resolution open => fixed
2010-10-28 00:49 Martin Friebe Note Added: 0042225
2010-10-28 00:49 Martin Friebe Target Version => 0.9.30
2010-11-14 18:43 Sven Barth Status resolved => assigned
2010-11-14 18:43 Sven Barth Resolution fixed => reopened
2010-11-14 18:43 Sven Barth Note Added: 0043045
2010-11-14 18:44 Sven Barth Note Edited: 0043045
2010-11-14 20:48 Martin Friebe Fixed in Revision 27910 => 27910, 28222
2010-11-14 20:48 Martin Friebe Status assigned => resolved
2010-11-14 20:48 Martin Friebe Resolution reopened => fixed
2010-11-14 20:48 Martin Friebe Note Added: 0043049
2010-11-15 11:16 Sven Barth Status resolved => closed
2010-11-15 11:16 Sven Barth Note Added: 0043061