Hello,

In message "[ruby-core:41800] Re: Best way to separate implementation specific code?"
    on Dec.25,2011 02:09:18, <kosaki.motohiro / gmail.com> wrote:
> > 1) Should files be named original_<platform>.c ?
> > E.g.: file_win32.c, file_unix.c, dir_win32.c
> 
> I don't think so. win32/file.c should be allowed. we haven't implemented
> such makefile rule, but not refuse to enhance it.

+1 to kosaki-san


> > 2) Should win32 files be placed in win32?
> 
> I think so.

I think so, too.



> > What about thread_win32.c
> > which doesn't follow the rule?
> 
> Difficult question. As far as I know, it is only historical reason.
> thread_win32.c was YARV related code and other don't.

kosaki-san is right.
Incidentally, I dislike this style.


> > 3) Should I move exiting POSIX version function to these _unix files?

or posix/*.c ?
Anyway, if the code for Windows is separated into another file,
and the code for UNIX is not separeted, #ifdef will remain in
file.c or others, after all.


Regards,
-- 
U.Nakamura <usa / garbagecollect.jp>