* Gnatbench 2.3.1 doing funny thing - any ideas?
@ 2009-08-05 10:40 John McCabe
2009-08-05 10:44 ` John McCabe
0 siblings, 1 reply; 4+ messages in thread
From: John McCabe @ 2009-08-05 10:40 UTC (permalink / raw)
I'm playing around with Eclipse Ganymede and Gnatbench (again).
I have a strange thing happening in the editor and haven't the
faintest idea where to look to see why this is happening so I hope
someone can point me in the right direction.
Basically I have a little program, just playing with it as a bit of a
reminder as I don't use Ada in anger these days...
1 ) with Ada.Text_Io;
2 ) with Ada.Integer_Text_Io;
3 ) with Ada.Exceptions;
4 )
5 ) procedure Mainproc is
6 )
7 ) protected type Mutex_Type is
8 ) entry Wait;
9 ) procedure Release;
10) private
11) Open : Boolean := True;
12) end Mutex_Type;
13)
14) protected body Mutex_Type is
15) entry Wait when Open is
16) begin
17) Open := False;
18) end Wait;
19)
20) procedure Release is
21) begin
22) Open := True;
23) end Release;
24) end Mutex_Type;
25)
26) Mutex_Po : Mutex_Type;
27)
28) task type Synctask_Po (Id : Integer) is
29) entry Startup;
30) end Synctask_Po;
31)
32) task body Synctask_Po is
33) Usual_Delay : constant Duration := 1.0 + Duration (Id) /
10.0;
34) begin
35) accept Startup;
36) while True
37) loop
38) Ada.Text_Io.Put_Line ("Task" & Integer'Image(Id) & ":
Waiting for Entry");
39) Mutex_Po.Wait;
40)
41) Ada.Text_Io.Put_Line ("Task" & Integer'Image(Id) & ": in
Critical Section");
42) delay Usual_Delay;
43)
44) Ada.Text_Io.Put_Line ("Task" & Integer'Image(Id) & ":
Releasing");
45) Mutex_Po.Release;
46) delay Usual_Delay;
47) end loop;
48) exception
49) when X : others =>
50) Ada.Text_Io.Put ("Exception occurred in synctask_po" &
51) Integer'Image(Id) &
52) ": " &
53) Ada.Exceptions.Exception_Name
(Ada.Exceptions.Exception_Identity (X)) &
54) " : " &
55) Ada.Exceptions.Exception_Message (X));
56) end Synctask_Po;
57)
58) type Synctask_Po_Access is access all Synctask_Po;
59) Synctask_Po_Arr : array (1 .. 3) of Synctask_Po_Access;
60)
61) begin
62) for I in 1 .. 3 loop
63) Synctask_Po_Arr (I) := new Synctask_Po (I);
64) Synctask_Po_Arr (I).Startup;
65) end loop;
66)
67) end Mainproc;
Now, on most lines, if I go to the start of the line and press the
enter key, it just gives me a blank line and moves the line I'm on
down one, putting the cursor at the start of the text. However, on
lines 38, 41 and 44 if I do that, it does the same sort of thing, but
prepends an extra "A" on to the line, so I get AAda.Text_Io...
In the Ada preferences, "Editor" section, I've got:
Save altered files before completion
Remove trailing spaces when saving
NOT Use smart space key
Minimum word lenght for expansion consideration = 3
Use smart tab key
Highlight matching brackets
Matching brackets highlight color [kind of grey]
NOT Insert header text into new Ada aource files
File containing.... both blank.
In the "Coding Style" I've got...
extended
3
2
1
3
0
automatic
lower_case
Mixed_Case
Format operators/delimiters
NOT use tabulations
NOT align colons
NOT align associations
NOT align declaration
Indent comments
NOT align comments
Any ideas anyone?
Thanks
John
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-08-05 17:12 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-08-05 10:40 Gnatbench 2.3.1 doing funny thing - any ideas? John McCabe
2009-08-05 10:44 ` John McCabe
2009-08-05 12:23 ` Britt
2009-08-05 17:12 ` John McCabe
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox