Skip to content

Commit eade0e9

Browse files
committed
v1.4.7
1 parent fb1df9b commit eade0e9

File tree

4 files changed

+11
-19
lines changed

4 files changed

+11
-19
lines changed

js/lib.ml

+9-13
Original file line numberDiff line numberDiff line change
@@ -50,20 +50,16 @@ let mldoc_object =
5050
print_endline (Printexc.to_string error);
5151
input
5252

53-
method export getReferences config_json input =
53+
method getReferences input config_json =
5454
let str = Js.to_string input in
55-
try
56-
let config_json = Yojson.Safe.from_string config_json in
57-
match Conf.of_yojson config_json with
58-
| Ok config -> (
59-
let result = Mldoc.Property.property_references config str in
60-
Mldoc.Type.inline_list_no_pos_to_yojson result |> Yojson.Safe.to_string |> Js.string)
61-
| Error e ->
62-
print_endline e;
63-
input
64-
with error ->
65-
print_endline (Printexc.to_string error);
66-
input
55+
let config_json = Js.to_string config_json in
56+
let config_json = Yojson.Safe.from_string config_json in
57+
match Conf.of_yojson config_json with
58+
| Ok config -> (
59+
let result = Mldoc.Property.property_references config str in
60+
Mldoc.Type.inline_list_no_pos_to_yojson result |> Yojson.Safe.to_string |> Js.string)
61+
| Error e ->
62+
Js_of_ocaml.Js.string ("Config error: " ^ e)
6763

6864
method export to_format input config_json references =
6965
let to_format = Js.to_string to_format in

js/package/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "mldoc",
3-
"version": "1.4.6",
3+
"version": "1.4.7",
44
"description": "Another Emacs Org-mode parser.",
55
"main": "index.js",
66
"scripts": {

lib/syntax/extended/hash_tag.ml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ let hashtag_name =
1313
<|> ( take_while (fun c -> List.mem c tag_delims)
1414
*> (satisfy is_space_eol *> return () <|> end_of_input)
1515
*> return `Finish
16-
<|> (String.make 1 <$> not_one_of [ '#' ] >>| fun c -> `Continue c)
16+
<|> (String.make 1 <$> not_one_of [ '#'; ','; '!'; '?'; '\''; '"'; ':' ] >>| fun c -> `Continue c)
1717
>>= fun r ->
1818
match r with
1919
| `Finish -> fail "hashtag_name_part finish"

move_js

-4
This file was deleted.

0 commit comments

Comments
 (0)