Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#718 closed Feature Request (Rejected)

Call() function claims "function doas not exist" if function was called with wrong number of arguments

Reported by: Hubertus Owned by:
Milestone: Component: AutoIt
Version: Severity: None
Keywords: Call() wrong number of arguments Cc:


In Beta , if a function exists but has wrong number of arguments in Call() function, @error and @extended are set to "0xDEAD and 0xBEEF".
Helpfile says "Sets @error to 0xDEAD and @extended to 0xBEEF if the function does not exist."

My proposal is: If function exsists, but has wrong number of arguments, set @extended to 0xBEE or any other nice hex-word.

Attachments (0)

Change History (3)

comment:1 Changed 15 years ago by TicketCleanup

  • Version Other deleted

Automatic ticket cleanup.

comment:2 Changed 15 years ago by Valik

  • Resolution set to Rejected
  • Status changed from new to closed

No. I'm not going to add a feature that's not needed so it can be immediately abused to solve a problem in the wrong way. All I'm going to do is document that @error and @extended are set on failure to call the function. I am not going to add in a separate @error/@extended value to check a condition that is largely irrelevant.

It is up to the API designer to lay forth the rules about callback functions such as the number of arguments. It is up to the callback designer to ensure their function accepts the correct number of arguments the API will be calling it with. There doesn't need to be functionality in the language to supplant proper communication/documentation.

comment:3 Changed 15 years ago by Valik

Never mind, JP already documented what I was going to.

Guidelines for posting comments:

  • You cannot re-open a ticket but you may still leave a comment if you have additional information to add.
  • In-depth discussions should take place on the forum.

For more information see the full version of the ticket guidelines here.

Add Comment

Modify Ticket

as closed The ticket will remain with no owner.

E-mail address and user name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.