Function prototyping (feature request)

Started by Radiant, Fri 17/09/2004 16:49:03

Previous topic - Next topic

Radiant


Would it be possible to add function prototyping to AGS? E.g.

Code: ags

declare function a (int, string);

function b (int) {
  a (4, "hello");
}

function a (int, string) {
  b (5);
}



Also compiler-related, it may be useful to generate a compiler error if the player uses for instance MoveCharacter (SOME_GUY, ...) if SOME_GUY is in fact the identifier for a view rather than for a character.

Pumaman

I can see how this would be useful, so I'll add it to my list, as a low priority feature.

As for your second point, it would be nice, but the current way the compiler works would make this difficult to implement. I'll think about it.

SMF spam blocked by CleanTalk