|
@@ -1819,27 +1819,17 @@ let check_global_metadata ctx meta f_add mpath tpath so =
|
|
let add = ((field_mode && to_fields) || (not field_mode && to_types)) && (match_path recursive sl1 sl2) in
|
|
let add = ((field_mode && to_fields) || (not field_mode && to_types)) && (match_path recursive sl1 sl2) in
|
|
if add then f_add m
|
|
if add then f_add m
|
|
) ctx.g.global_metadata;
|
|
) ctx.g.global_metadata;
|
|
- if ctx.is_display_file then match ctx.com.display.dms_kind with
|
|
|
|
- | DMType ->
|
|
|
|
- List.iter (fun (meta,_,p) ->
|
|
|
|
- if Display.is_display_position p then match meta with
|
|
|
|
- | Meta.Custom _ | Meta.Dollar _ -> ()
|
|
|
|
- | _ -> match MetaInfo.get_documentation meta with
|
|
|
|
- | None -> ()
|
|
|
|
- | Some (_,s) ->
|
|
|
|
- (* TODO: hack until we support proper output for hover display mode *)
|
|
|
|
- raise (Display.Metadata ("<metadata>" ^ s ^ "</metadata>"));
|
|
|
|
- ) meta
|
|
|
|
- | DMField ->
|
|
|
|
- List.iter (fun (meta,_,p) ->
|
|
|
|
- if Display.is_display_position p then begin
|
|
|
|
- let all,_ = MetaInfo.get_documentation_list() in
|
|
|
|
- let all = List.map (fun (s,doc) -> (s,Display.FKMetadata,Some doc)) all in
|
|
|
|
- raise (Display.DisplayFields all)
|
|
|
|
|
|
+ if ctx.is_display_file then begin
|
|
|
|
+ List.iter (fun (meta,args,p) ->
|
|
|
|
+ if Display.is_display_position p then Display.DisplayEmitter.display_meta ctx.com.display meta;
|
|
|
|
+ List.iter (fun e ->
|
|
|
|
+ if Display.is_display_position (pos e) then begin
|
|
|
|
+ let e = Display.ExprPreprocessing.process_expr ctx.com e in
|
|
|
|
+ ignore(type_expr ctx e Value);
|
|
end
|
|
end
|
|
- ) meta
|
|
|
|
- | _ ->
|
|
|
|
- ()
|
|
|
|
|
|
+ ) args
|
|
|
|
+ ) meta
|
|
|
|
+ end
|
|
|
|
|
|
let patch_class ctx c fields =
|
|
let patch_class ctx c fields =
|
|
let path = match c.cl_kind with
|
|
let path = match c.cl_kind with
|