소스 검색

Correctly handle case of missing function call arguments.

woollybah 10 년 전
부모
커밋
e682e157a8
2개의 변경된 파일4개의 추가작업 그리고 4개의 파일을 삭제
  1. 3 3
      decl.bmx
  2. 1 1
      options.bmx

+ 3 - 3
decl.bmx

@@ -873,11 +873,11 @@ End Rem
 					
 					If Not explicit And exprTy.ExtendsType( declTy ) Continue
 
-				Else If argDecls[i].init
+				Else If Not argDecls[i].init
 
-					exact=False
+					' if this argument is missing and there isn't a default...
+					Err "Missing function parameter '" + argDecls[i].ident + "'"
 
-					If Not explicit Exit
 				Else
 					If func.attrs & FUNC_PTR Then
 						exact=False

+ 1 - 1
options.bmx

@@ -25,7 +25,7 @@ SuperStrict
 
 Import "base.configmap.bmx"
 
-Const version:String = "0.40"
+Const version:String = "0.41"
 
 Const BUILDTYPE_APP:Int = 0
 Const BUILDTYPE_MODULE:Int = 1