// TODO: convert to static method; caller parameter doesn't belong here /// <exception cref="InterpreterError"><paramref name="argspec"/> is invalid.</exception> public ZilFunction([NotNull] string caller, [CanBeNull] ZilAtom name, [CanBeNull] ZilAtom activationAtom, [NotNull][ItemNotNull] IEnumerable <ZilObject> argspec, ZilDecl decl, [ItemNotNull][NotNull] IEnumerable <ZilObject> body) { this.argspec = ArgSpec.Parse(caller, name, activationAtom, argspec, decl); this.body = body.ToArray(); }
/// <exception cref="InterpreterError"><paramref name="argspec"/> is invalid.</exception> public ZilFunction([CanBeNull] ZilAtom name, [CanBeNull] ZilAtom activationAtom, [NotNull][ItemNotNull] IEnumerable <ZilObject> argspec, ZilDecl decl, [ItemNotNull][NotNull] IEnumerable <ZilObject> body) : this("<internal>", name, activationAtom, argspec, decl, body) { }