* Re: string literals [not found] <cary-110195174515@macsac09.esl.com> @ 1995-01-12 22:21 ` Robert Dewar [not found] ` <D2Dnpv.41u@alsys.com> 1995-01-13 13:31 ` Pascal OBRY 1 sibling, 1 reply; 6+ messages in thread From: Robert Dewar @ 1995-01-12 22:21 UTC (permalink / raw) "but don't want to use [the package with character literals]" why on earth not? this is what use is for! There is a certain style of Ada question that goes like: How do I do X without using Y where Y is exactly the feature intended to support X. Most odd! If you are worried that the use clause would clutter up the name space, a nice way of doing things is to put the definition of the character type into a nested package: package Stuff is ... package Char_Type_Package is type Char_Type is ( .... end Char_Type_Package; end Stuff; now you can just say use Stuff.Char_Type_Package and you have access to the literals. ^ permalink raw reply [flat|nested] 6+ messages in thread
[parent not found: <D2Dnpv.41u@alsys.com>]
[parent not found: <3fbtgk$501@gnat.cs.nyu.edu>]
[parent not found: <3fcdf4$65n@uuneo.neosoft.com>]
* Re: string literals [not found] ` <3fcdf4$65n@uuneo.neosoft.com> @ 1995-01-16 17:30 ` Robert Dewar 0 siblings, 0 replies; 6+ messages in thread From: Robert Dewar @ 1995-01-16 17:30 UTC (permalink / raw) An absolute rule against all use clauses is misconceived and ill-advised, but you can live with it, because the consequence is just junky hard to read source code, and tools can hide the junk from you. An absolute rule against all use of unchecked conversion is true folly. There are all sorts of situations in which UC is an important tool, and completely forbidding its use seriously cripples the language. Sure it can be misused, so can addition and integers, but that doesn't mean you should ban addition and integers. Indeed the requirement of an explicit with of unchecked conversion is precisely intended to allow *control* of the use of this important feature, not its *elimination*. I can't tell you how many times I have seen people decide that you can't do something in Ada, and therefore resort to C, or whatever, just because they have crippled Ada with silly restrictions. ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: string literals [not found] ` <3fbtgk$501@gnat.cs.nyu.edu> [not found] ` <3fcdf4$65n@uuneo.neosoft.com> @ 1995-01-18 13:24 ` Richard G. Hash 1995-01-21 5:20 ` Robert Dewar 1995-01-21 13:09 ` Rolf Ebert 1 sibling, 2 replies; 6+ messages in thread From: Richard G. Hash @ 1995-01-18 13:24 UTC (permalink / raw) In <3fbtgk$501@gnat.cs.nyu.edu> dewar@cs.nyu.edu (Robert Dewar) writes: > > Also, Keith says that it is as hard to look at a variable and know where > it came from as [...] > > Nonsense, the first question can be answered by a trivial tool, you should > indeed be able to click on an identifier and have a window pop up with > the declaration. [...] Since this tool will be so "trivial", I hope you plan on including it in the GNAT effort. Can we expect it by, oh, say, next month? 1/2 ;-) -- Richard G. Hash email: rgh@shell.com Shell Development Company, Bellaire Research Center phone: (713) 245-7311 Member Team Ada Free Ada95 compilers: cs.nyu.edu:/pub/gnat ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: string literals 1995-01-18 13:24 ` Richard G. Hash @ 1995-01-21 5:20 ` Robert Dewar 1995-01-21 13:09 ` Rolf Ebert 1 sibling, 0 replies; 6+ messages in thread From: Robert Dewar @ 1995-01-21 5:20 UTC (permalink / raw) "Since this tool will be so "trivial", I hope you plan on including it in the GNAT effort. Can we expect it by, oh, say, next month?" certainly not by next month, but I would hope this would happen soon. Tools for GNAT have to be mostly fashioned outside NYU, since NYU (and the GNAT contract) are concentrated on the compiler itself. However, I do expect various interesting things to be happening in the tool department, stay tuned! ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: string literals 1995-01-18 13:24 ` Richard G. Hash 1995-01-21 5:20 ` Robert Dewar @ 1995-01-21 13:09 ` Rolf Ebert 1 sibling, 0 replies; 6+ messages in thread From: Rolf Ebert @ 1995-01-21 13:09 UTC (permalink / raw) >>>>> "Richard" == Richard G Hash <rgh@shell.com> writes: Richard> In <3fbtgk$501@gnat.cs.nyu.edu> dewar@cs.nyu.edu (Robert Dewar) Richard> writes: >> Also, Keith says that it is as hard to look at a variable and know >> where it came from as [...] >> >> Nonsense, the first question can be answered by a trivial tool, you >> should indeed be able to click on an identifier and have a window pop >> up with the declaration. [...] Richard> Since this tool will be so "trivial", I hope you plan on Richard> including it in the GNAT effort. Can we expect it by, oh, say, Richard> next month? Richard> 1/2 ;-) It's already there! Try Emacs with the latest Ada Mode on cs.nyu.edu:/pub/gnat. It contains a support mode for the gnat Xreferencer GNATF. Click with the mouse on an identifier, Emacs will place your cursor at its declaration. The tool knows everthing about overloading, record fields, etc. The current release 2.12 of the Ada Mode has a problem, if the xref information is not immidiately available (i.e. must be regenerated). This will be fixed in the upcoming 2.13. Richard> -- Richard G. Hash email: rgh@shell.com Shell Development Richard> Company, Bellaire Research Center phone: (713) 245-7311 Member Richard> Team Ada Free Ada95 compilers: cs.nyu.edu:/pub/gnat Rolf -- Rolf Ebert Beratung fuer Energiesysteme und Informatik Erich Kaestner Str. 17 Conseil en Energetique et Informatique D - 80796 Muenchen (Team Ada) Tel.: +49-89-30.77.88.00 Germany Fax.: +49-89-30.77.91.00 ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: string literals [not found] <cary-110195174515@macsac09.esl.com> 1995-01-12 22:21 ` string literals Robert Dewar @ 1995-01-13 13:31 ` Pascal OBRY 1 sibling, 0 replies; 6+ messages in thread From: Pascal OBRY @ 1995-01-13 13:31 UTC (permalink / raw) Cary Jamison wrote : >but I can't find a way to do anything like > > My_String : Pkg1.Big_String(1..5) := Pkg1."Hello"; > >other than (Pkg1.'H', Pkg1.'e', ...) Well with Ada9x you can use a single type without do a use of the full package. see use type (RM 8.4) You should be able to write : use type Pkg1.Big_Char; My_String : Pkg1.Big_String(1..5) := "Hello"; I think this address your problem. Pascal. -- --|--------------------------------------------------------------- --| Pascal OBRY e-mail: pascal.obry@der.edf.fr | --| EDF-DER-IPN-SID-ISI | --| Bureau G1-010 voice: +33-1-47.65.50.91 | --| 1 Av General de Gaulle | --| 92141 Clamart CEDEX | --| FRANCE | --|--------------------------------------------------------------- ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~1995-01-21 13:09 UTC | newest] Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <cary-110195174515@macsac09.esl.com> 1995-01-12 22:21 ` string literals Robert Dewar [not found] ` <D2Dnpv.41u@alsys.com> [not found] ` <3fbtgk$501@gnat.cs.nyu.edu> [not found] ` <3fcdf4$65n@uuneo.neosoft.com> 1995-01-16 17:30 ` Robert Dewar 1995-01-18 13:24 ` Richard G. Hash 1995-01-21 5:20 ` Robert Dewar 1995-01-21 13:09 ` Rolf Ebert 1995-01-13 13:31 ` Pascal OBRY
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox