list/proc/MyProc(arg1,arg2,etc)
//code runs through here
return
//---
var/list/MyList=new
MyList.MyProc(1,2,3)
//Or at least
datum/proc/DatumProc(arg1,arg2,etc)
var/list/Src=src
if(!istype(Src)){return}
//code runs through here
return
//---
var/list/MyList=new
MyList.DatumProc(1,2,3)
Being able to define procs under the list or savefile type instead of having procs where their first argument is a list or a savefile. We can already define procs on nearly any other type. Why not lists and savefiles too?
If not being able to define the type under savefiles or lists, we should at least be able to define a datum proc that can be called on a list. What I mean is that you should finally do what is noted in the help file and make savefiles or lists derived from /datum so that we can call a datum proc on a list.
Before anyone replies, I know you can do this:
proc/MyProc(list/L,arg1,arg2,etc)
//code runs through here
return
If you're just going to talk about how this can already be done by making the first argument of a proc a list, then please don't reply. I already know this. The staff knows this. It's up to the staff whether or not they implement my suggestion in the future. I know it's not high-priority and I'm not asking for anything now. It's just a suggestion.
Being able to define procs under the list or savefile type instead of having procs where their first argument is a list or a savefile. We can already define procs on nearly any other type. Why not lists and savefiles too?
I like this idea quite a lot. I'm not sure how difficult it would be but I'd like to be able to do it.
Is this concept plausible? If so... Win! :D