소스 검색

[display] ignore version() args for hover

makes the behavior consistent with hover on regular functions, which also doesn't require the arguments to be correct
Jens Fischer 6 년 전
부모
커밋
64ee23ad74
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      src/typing/typeloadParse.ml

+ 1 - 1
src/typing/typeloadParse.ml

@@ -172,7 +172,7 @@ module ConditionDisplay = struct
 		let tpair t = (t,CompletionItem.CompletionType.from_type (fun _ -> Imported) t) in
 		let tpair t = (t,CompletionItem.CompletionType.from_type (fun _ -> Imported) t) in
 		let check_expr (e,p) =
 		let check_expr (e,p) =
 			match e with
 			match e with
-				| ECall ((EConst (Ident "version"),p),[(EConst (String(s,_)), _)])  ->
+				| ECall ((EConst (Ident "version"),p),_)  ->
 					let t = TFun ([("s",false,com.basic.tstring)],t_semver) in
 					let t = TFun ([("s",false,com.basic.tstring)],t_semver) in
 					if check_position p then
 					if check_position p then
 						DisplayException.raise_hover (CompletionItem.make_ci_class_field {
 						DisplayException.raise_hover (CompletionItem.make_ci_class_field {