From: Jean Privat Date: Mon, 24 Aug 2015 19:49:17 +0000 (-0400) Subject: loader: get_mgroup filter out non-directories X-Git-Tag: v0.7.8~69^2~7 X-Git-Url: http://nitlanguage.org loader: get_mgroup filter out non-directories This was implicit because non-directories do not match the heuristics Signed-off-by: Jean Privat --- diff --git a/src/loader.nit b/src/loader.nit index 53b2234..2516f3a 100644 --- a/src/loader.nit +++ b/src/loader.nit @@ -388,6 +388,13 @@ redef class ModelBuilder return mgroups[rdp] end + # Filter out non-directories + var stat = dirpath.file_stat + if stat == null or not stat.is_dir then + mgroups[rdp] = null + return null + end + # Hack, a group is determined by one of the following: # * the presence of a honomymous nit file # * the fact that the directory is named `src`