File tree Expand file tree Collapse file tree 1 file changed +39
-0
lines changed Expand file tree Collapse file tree 1 file changed +39
-0
lines changed Original file line number Diff line number Diff line change 1
1
# Changelog
2
2
3
+ ## Unreleased
4
+
5
+ ### Language server
6
+
7
+ - The language server nof offers code action to add type annotations to all
8
+ functions and constants. For example,
9
+
10
+ ``` gleam
11
+ pub const answer = 42
12
+
13
+ pub fn add(x, y) {
14
+ x + y
15
+ }
16
+
17
+ pub fn add_one(thing) {
18
+ // ^ Triggering "Annotate all top level type definitions" code action here
19
+ let result = add(thing, 1)
20
+ result
21
+ }
22
+ ```
23
+
24
+ Triggering the "Annotate all top level type definitions" code action over
25
+ the name of function ` add_one ` would result in following code:
26
+
27
+ ``` gleam
28
+ pub const answer: Int = 42
29
+
30
+ pub fn add(x: Int, y: Int) -> Int {
31
+ x + y
32
+ }
33
+
34
+ pub fn add_one(thing: Int) -> Int {
35
+ let result = add(thing, 1)
36
+ result
37
+ }
38
+ ```
39
+
40
+ ([ Andrey Kozhev] ( https://github.com/ankddev ) )
41
+
3
42
## v1.13.0-rc1 - 2025-09-29
4
43
5
44
### Compiler
You can’t perform that action at this time.
0 commit comments