From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.6 required=5.0 tests=BAYES_00, FILL_THIS_FORM_FRAUD_PHISH,FREEMAIL_FROM,T_FILL_THIS_FORM_SHORT, WEIRD_PORT autolearn=no autolearn_force=no version=3.4.4 X-Received: by 10.140.235.193 with SMTP id g184mr18545600qhc.10.1446467639216; Mon, 02 Nov 2015 04:33:59 -0800 (PST) X-Received: by 10.182.210.134 with SMTP id mu6mr199328obc.20.1446467639182; Mon, 02 Nov 2015 04:33:59 -0800 (PST) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!feeder.eternal-september.org!usenet.blueworldhosting.com!feeder01.blueworldhosting.com!peer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!c107no4035954qgd.1!news-out.google.com!z4ni43823ign.0!nntp.google.com!i2no1650001igv.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Mon, 2 Nov 2015 04:33:59 -0800 (PST) Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=82.243.252.139; posting-account=zd4fUAoAAABZGnAfDxrdJ5Lpts-qUilv NNTP-Posting-Host: 82.243.252.139 User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re : Simple call of Procedure with Ada.float_text_IO.Get From: comicfanzine@gmail.com Injection-Date: Mon, 02 Nov 2015 12:33:59 +0000 Content-Type: text/plain; charset=ISO-8859-1 X-Received-Bytes: 3824 X-Received-Body-CRC: 2431289238 Xref: news.eternal-september.org comp.lang.ada:28173 Date: 2015-11-02T04:33:59-08:00 List-Id: Hi , i have a code with a procedure call and i got the following errors , i understand them but i don't know how to fixe them : log_in.adb:28:17: no candidate interpretations match the actuals: log_in.adb:28:17: missing argument for parameter "From" in call to "get" declared at identification.ads:8 log_in.adb:28:17: missing argument for parameter "Password" in call to "get" declared at identification.ads:7 I have 3 files (packagefile.adb , packagefile.ads and the mainprogram(log_in) : ================= with Ada.Text_IO; with Identification; with Ada.float_text_IO; Procedure log_in is Procedure check_password is Password : Identification.Password_Value; begin Identification.Get (Password => Password); if Password = "admin" then Ada.Text_IO.Put_Line (Item => "Welcome, Administrator."); end if; end check_password; virgules : Identification.virgules_Value ; begin check_password; -- Here i want the procedure check_password be executed before log_in , for the arguments given to Ada.float_text_IO.Get Identification.Get (virgules => virgules); if virgules'Valid then Ada.Text_IO.Put_Line("A float number was not asked") ; end if; end log_in; ================= with Ada.Text_IO; with Ada.Float_Text_IO; package body identification is procedure Get (Password : out Password_Value ) is procedure Get (From : in Password_Value; Item : out virgules_Value; Last : out Positive_package_declaration_need); is begin Ada.float_text_IO.get(Item => virgules); Skip_line ; end Get; begin Ada.Text_IO.Put (Item => "Hello, User. What's your name? "); Get_Name : declare Name : constant String := Ada.Text_IO.Get_Line; begin if Name /= "fanzine" then Ada.Text_IO.Put_Line (Item => "You're not Administrator."); procedure Get (From : in Password_Value; Item : out virgules_Value; Last : out Positive_package_declaration_need); else Ada.Text_IO.Get (Item => Password); Ada.Text_IO.Skip_Line; Ada.Text_IO.New_Line; end if; end Get_Name; end Get; end identification; ===================== package identification is subtype Password_Value is String (1..5); subtype virgules_Value is Float ; subtype Positive_package_declaration_need is Positive ; procedure Get (Password : out Password_Value); procedure Get (From : in Password_Value; Item : out virgules_Value; Last : out Positive_package_declaration_need); -- "Last" is in the declaration in Ada.float_text_IO.Get , i don't know if i can , not use it and if it silll going to work after that . end identification;