Because of how I list the entries in a directory ([see line 213 of site.rb](https://github.com/rdumont/jekyll/commit/604fb3286c9e9625912e45d31b07e18fc79f56aa#diff-30570eaa19766a40dfa44810430d5e16R213)), directories will always override whatever is read from a file with the same name.

But this is due to a small detail in implementation. I think the behavior for such case should be considered unpredictable and people should be discouraged to name files the same as sub-directories. Just the same as they shouldn't have a `.json` and a `.yaml` with the same name.