From: Niklas Holsti <nholsti@icon.fi>
Subject: Re: making music
Date: 1998/04/26
Date: 1998-04-26T00:00:00+00:00 [thread overview]
Message-ID: <3543415F.E097D443@icon.fi> (raw)
In-Reply-To: 3542664f.0@news.thefree.net
JimBOB wrote:
>
> hello,
> hopefully you can help me..
> I'm writing for Linux.. or any other port!
>
> I compiled a small body of code,
>
> with text_io,basic_num,mcc-sounds;
> use text_io,basic_num,mcc-sounds;
The package name "mcc-sounds" is incorrect; Ada does not allow
a hyphen in names. Perhaps you meant "mcc_sounds" ?
(This is one of the rare cases in which the GNAT error message
is not very precise.)
> procedure play_for_me is
> wav:string;
You should also define the length of the "wav" string, ie.
constrain it with an index range such as
wav: string (1..50);
> begin
> put("what wav file would you like to listen to?");
> get(wav);
You may want to modify the "get" call so that the user can enter
a string that is shorter than the total length of "wav".
Hope this helps...
- Niklas
> Play_Sound(wav);
> end play_for_me;
>
> With a package body from ftp.usafa... I tried to get this to work, but it
> tells me:
>
> play_for_me.adb:4:27:is missing";"
> play_for_me.adb:5:27:is missing";"
> gnatmake:"play_for_me.adb"compilation error
>
> Hopefully you know the package body stuff, or should I send that to?
> I can't see that Im missing a ";" anywhere!
>
> Any help will be appreciated.
prev parent reply other threads:[~1998-04-26 0:00 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <35397BC6.2A85CEAC@wvnet.at>
[not found] ` <35398fdf.116942877@news.nextdim.com>
1998-04-24 0:00 ` making music JimBOB
1998-04-26 0:00 ` Simon Wright
1998-04-26 0:00 ` Niklas Holsti [this message]
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox