Closed dumblob closed 11 years ago
Actually, cwd() is a static method of fsnode, so it can be called by:
fsnode::cwd()
fsnode.cwd()
If you use "load fs as fs", simply prefix the above codes with "fs::" or "fs.".
Of course, cwd() can be implemented module specific method, but here, it seems more natural to have it as static method of fsnode.
Thank you, my fault, I'm ashamed.
I'm just curious why the
fs
module from theos
directory behaves like is shown at the bottom. I assume, the declarations in thefsnodeMeths[]
array indao_fs.c
withself
as a the first argument are methods and the rest are module-specific routines accessible usingmodule_name.module_specific_routine()
syntax.with module "renaming":