compiler: rename compilation dir as `nit_compile`
[nit.git] / src / compiler / abstract_compiler.nit
index 1b8bf6a..48a19a8 100644 (file)
@@ -149,7 +149,7 @@ class Toolchain
        fun compile_dir: String
        do
                var compile_dir = toolcontext.opt_compile_dir.value
-               if compile_dir == null then compile_dir = ".nit_compile"
+               if compile_dir == null then compile_dir = "nit_compile"
                return compile_dir
        end
 
@@ -327,7 +327,7 @@ class MakefileToolchain
                var outpath = real_outpath.escape_to_mk
                if outpath != real_outpath then
                        # If the name is crazy and need escaping, we will do an indirection
-                       # 1. generate the binary in the .nit_compile dir under an escaped name
+                       # 1. generate the binary in the nit_compile dir under an escaped name
                        # 2. copy the binary at the right place in the `all` goal.
                        outpath = mainmodule.c_name
                end
@@ -1173,6 +1173,8 @@ abstract class AbstractCompilerVisitor
                        var param = msignature.mparameters[i]
                        var j = map.map.get_or_null(i)
                        if j == null then
+                               # default value
+                               res.add(null_instance)
                                continue
                        end
                        if param.is_vararg and map.vararg_decl > 0 then
@@ -3119,6 +3121,13 @@ redef class AVarargExpr
        end
 end
 
+redef class ANamedargExpr
+       redef fun expr(v)
+       do
+               return v.expr(self.n_expr, null)
+       end
+end
+
 redef class ADebugTypeExpr
        redef fun stmt(v)
        do