Re: GPS project file can not be edited graphically
"Vo, Anh (US SSA)" <[email protected]> Thu, 2 Jun 2011 10:31:17 -0500
| Newsgroups | gmane.comp.ide.gps.user |
|---|---|
| Message-ID | <[email protected]> |
I got it now. Thank you very much. -----Original Message----- From: Emmanuel Briot [mailto:[email protected]] Sent: Monday, May 30, 2011 12:31 AM To: Vo, Anh (US SSA) Cc: [email protected] Subject: Re: [gps-users] GPS project file can not be edited graphically > My question is that why GPS does not complain declaration and initialization, > shown below, while assignment statement is used in both cases. > > type OS_Kind is ("Windows_NT", "unix"); > > OS : OS_Kind := external ("OS", "unix"); Because this is a special case of variable, referencing an external value. GPS treats these specially, and displays them in the Scenario view. The reason it does not handle standard variables is that it would be difficult to preserve the user's project in such cases, for instance: project Default is Var := "foo"; case OS is when "unix" => Var := "foo_unix"; when "Windows_NT" => Var := "foo_win"; end case; end Default; then GPS would only see the final value of the variable based on the current scenario, and would not know that the user wants to 'isolate' the 'foo' part. Since such projects cannot be created graphically anyway, we just assume the user knows what he is doing and will keep editing the project textually. Emmanuel