ocaml: Small query improvements and fix autoclose brackets (#7769)

Turns out auto-closing words was a bad idea. win**do**w, **struct**ure,
**sig**n and so on

They don't serve any purpose in `config.toml` nor `brackets.scm` at this
point, so I removed them>

Release Notes:
- N/A
This commit is contained in:
rmu 2024-02-25 04:06:25 +04:00 committed by GitHub
parent 401798d9b8
commit dbe1f48f95
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 6 additions and 20 deletions

View file

@ -1,6 +1,3 @@
("(" @open ")" @close)
("{" @open "}" @close)
("<" @open ">" @close)
("sig" @open "end" @close)
("object" @open "end" @close)

View file

@ -7,8 +7,5 @@ brackets = [
{ start = "{", end = "}", close = true, newline = true },
{ start = "<", end = ">", close = true, newline = true },
{ start = "[", end = "]", close = true, newline = true },
{ start = "(", end = ")", close = true, newline = true },
{ start = "sig", end = " end", close = true, newline = true },
# HACK: For some reason `object` alone does not work
{ start = "object ", end = "end", close = true, newline = true },
{ start = "(", end = ")", close = true, newline = true }
]

View file

@ -5,8 +5,3 @@
("<" @open ">" @close)
("\"" @open "\"" @close)
("begin" @open "end" @close)
("struct" @open "end" @close)
("sig" @open "end" @close)
("object" @open "end" @close)
("do" @open "done" @close)

View file

@ -9,11 +9,5 @@ brackets = [
{ start = "[", end = "]", close = true, newline = true },
{ start = "[|", end = "|", close = true, newline = true, not_in = ["string"] },
{ start = "(", end = ")", close = true, newline = true },
{ start = "\"", end = "\"", close = true, newline = false, not_in = ["string"] },
{ start = "begin", end = " end", close = true, newline = true },
{ start = "struct", end = " end", close = true, newline = true },
{ start = "sig", end = " end", close = true, newline = true },
# HACK: For some reason `object` alone does not work
{ start = "object ", end = "end", close = true, newline = true },
{ start = "do", end = " done", close = true, newline = true }
{ start = "\"", end = "\"", close = true, newline = false, not_in = ["string"] }
]

View file

@ -8,7 +8,8 @@
[(class_name) (class_type_name) (type_constructor)] @type
[(constructor_name) (tag)] @constructor
(tag) @variant ;; Polymorphic Variants
(constructor_name) @constructor ;; Exceptions, variants and the like
; Functions
;----------

View file

@ -14,6 +14,8 @@
(field_declaration)
(field_expression)
(application_expression)
] @indent
(_ "[" "]" @end) @indent