Dear Lexicos,
In my opinion, it would be much better than the current codes after adopting my suggestion like the below Code1.
Code1:
Code: Select all
class cls1 {
__New() {
this.cc:=77
}
static class ff ; It is equivalent to the current nested class which is without static
{
}
class ff ; It will define a class-like method just like what happened in Python. It is completely equivalent to Code2 which is based on current V2.0.0.
{
static call(ths){
OutputDebug(ths.cc)
}
}
}
c:=cls1()
c.ff()
Code: Select all
#Requires AutoHotkey v2.0
class Cls1 {
__New() {
this.cc:=77
}
}
cls1.Prototype.DefineProp('ff',{call:ff})
class ff {
static call(ths){
OutputDebug(ths.cc)
}
}
c:=cls1()
c.ff()