Releases: grain-lang/grain
Releases · grain-lang/grain
Preview
stdlib: v0.7.1
Grain v0.7.1
0.7.1 (2025-07-01)
Features
- graindoc: Add locations to Graindoc errors (#2291) (da6090a)
- graindoc: Pretty markdown tables (#2292) (1992734)
- grainlsp: Add inlay types (#2005) (f8a8f7f)
- lsp: Implement document symbol outline (#2298) (e4caac2)
- stdlib: Add
Buffer.getChar
(#2262) (95d03cb) - stdlib: Deprecate
Buffer.set
operations in favour ofBytes.set
(#2303) (684df98) - stdlib: Expose equality operators through
Number
module (#2296) (5965dff)
Bug Fixes
- compiler: Correct type printing of
type A = a
(#2302) (ac892d1) - grainfmt: Correct formatting of submodules ending with comments (#2288) (f969df9)
cli: 0.7.1
0.7.1 (2025-07-01)
Miscellaneous Chores
- cli: Synchronize Grain versions
compiler: 0.7.1
0.7.1 (2025-07-01)
Features
- graindoc: Add locations to Graindoc errors (#2291) (da6090a)
- graindoc: Pretty markdown tables (#2292) (1992734)
- grainlsp: Add inlay types (#2005) (f8a8f7f)
- lsp: Implement document symbol outline (#2298) (e4caac2)
- stdlib: Add
Buffer.getChar
(#2262) (95d03cb)
Bug Fixes
- compiler: Correct type printing of
type A = a
(#2302) (ac892d1) - grainfmt: Correct formatting of submodules ending with comments (#2288) (f969df9)
stdlib: 0.7.1
0.7.1 (2025-07-01)
Features
cli: v0.7.1
stdlib: v0.7.0
0.7.0 (2025-04-26)
⚠ BREAKING CHANGES
- cli: Require node
>=22.13
(#2256) - compiler: Disallow whitespace for negative literals + allow infix operators on new line (#2136)
- compiler: Custom Grain object files (#2104)
- stdlib: Seeded hashing (#2170)
- stdlib: Add an
Ascii
submodule toChar
and moveisAscii
,toUppercase
,toLowercase
(#2178)
Features
- Add
getAll
,setAll
,removeAll
toList.Associative
(#2224) (9c49a23) - compiler: Custom Grain object files (#2104) (4b56c53)
- compiler: Disallow whitespace for negative literals + allow infix operators on new line (#2136) (3186155)
- runtime: Optimize
==
for lists (#2247) (1cba005) - runtime: Prevent stack overflow while collecting large lists (#2248) (097ae7d)
- runtime: Simplify
copy
andfill
polyfills inMemory
module (#2148) (1b3a9f0) - stdlib:
List.Associative
Submodule (#2202) (fbb08bf) - stdlib: Add
**
toFloat64
andFloat32
(#2163) (7542d92) - stdlib: Add
Array.tryInit
(#2209) (218ff78) - stdlib: Add
Bytes.setChar
andBytes.getChar
(#2215) (4919ba3) - stdlib: Add
Char.encodedLength
(#2238) (c549fac) - stdlib: Add
copySign
,sqrt
,min
,max
,round
,trunc
,floor
,ceil
toFloat32
(#2161) (f5a3dd3) - stdlib: Add
copySign
,sqrt
,min
,max
,round
,trunc
,floor
,ceil
toFloat64
(#2162) (e99dcba) - stdlib: Add
Exception.toString
(#2143) (0894dc5) - stdlib: Add
isFinite
,isClose
,sin
,cos
,tan
to Float32 (#2168) (bdb4641) - stdlib: Add
isFinite
,isClose
,sin
,cos
,tan
to Float64 (#2166) (fa728d2) - stdlib: Add
List.filterMap
,List.filterMapi
,List.findMap
(#2201) (551f5ad) - stdlib: add
Path.removeExtension
(#2226) (7b7acfd) - stdlib: Add
Path.updateExtension
(#2282) (6d795d0) - stdlib: Add
String.repeat
toString
module (#2140) (6c33d08) - stdlib: Add
toList
,fromList
,toArray
,fromArray
to Stack (#2198) (b815bcd) - stdlib: Add an
Ascii
submodule toChar
and moveisAscii
,toUppercase
,toLowercase
(#2178) (328cf01) - stdlib: Add user-friendly file system module (#1966) (c4f638e)
- stdlib: Implement
reinterpret
between float and int values (#2257) (e3a4eac) - stdlib: Json value access utils (#2150) (72cc978)
- stdlib: Optimize
List.init
to support large lists (#2249) (3de64ba) - stdlib: Reimplement
Number.gamma
andNumber.factorial
(#2182) (1e5f921) - stdlib: Reimplement
Number.sin
,Number.cos
,Number.tan
(#2158) (f97c011) - stdlib: Seeded hashing (#2170) (ce872ab)
Bug Fixes
- compiler: Handle non-exhaustive record patterns (#2274) (0431e74)
- runtime: Correct
Bi.toFloat64
rounding (#2160) (6755782) - stdlib: Correct sign bit in
_rempio
when computing trig reduction (#2181) (6a78502) - stdlib: Optimize number modulo (#2144) (960fadd)
- stdlib: Properly print
Range
values (#2184) (11b1fc2)
Miscellaneous Chores
Grain v0.7.0
0.7.0 (2025-04-26)
⚠ BREAKING CHANGES
- cli: Require node
>=22.13
(#2256) - compiler: Disallow whitespace for negative literals + allow infix operators on new line (#2136)
- compiler: Custom Grain object files (#2104)
- Remove
->
token in favor of=>
(#2177) - stdlib: Seeded hashing (#2170)
- stdlib: Add an
Ascii
submodule toChar
and moveisAscii
,toUppercase
,toLowercase
(#2178)
Features
- Add
getAll
,setAll
,removeAll
toList.Associative
(#2224) (9c49a23) - cli: Support node v22 and v23 (#2207) (130c494)
- compiler: Custom Grain object files (#2104) (4b56c53)
- compiler: Deduplicate foreign imports (#2233) (e8a3ed2)
- compiler: Disallow whitespace for negative literals + allow infix operators on new line (#2136) (3186155)
- compiler: Enable single-file compilation (#2105) (824b365)
- compiler: Improve exhaustive warning for lists (#2220) (f54dbdf)
- compiler: Use location for
Unbound_label_with_alt
error (#2196) (271d7cb) - compiler: Use program location for
_gmain
(#2231) (bdbbd05) - docs: Update
stdlib
contributor guidelines (#2277) (9631e72) - fmt: Add trailing comma on inline records (#2266) (cbe12e2)
- lsp: Add or remove block braces code action (#2222) (3134504)
- Remove
->
token in favor of=>
(#2177) (d0038d3) - runtime: Optimize
==
for lists (#2247) (1cba005) - runtime: Prevent stack overflow while collecting large lists (#2248) (097ae7d)
- runtime: Simplify
copy
andfill
polyfills inMemory
module (#2148) (1b3a9f0) - stdlib:
List.Associative
Submodule (#2202) (fbb08bf) - stdlib: Add
**
toFloat64
andFloat32
(#2163) (7542d92) - stdlib: Add
Array.tryInit
(#2209) (218ff78) - stdlib: Add
Bytes.setChar
andBytes.getChar
(#2215) (4919ba3) - stdlib: Add
Char.encodedLength
(#2238) (c549fac) - stdlib: Add
copySign
,sqrt
,min
,max
,round
,trunc
,floor
,ceil
toFloat32
(#2161) (f5a3dd3) - stdlib: Add
copySign
,sqrt
,min
,max
,round
,trunc
,floor
,ceil
toFloat64
(#2162) (e99dcba) - stdlib: Add
Exception.toString
(#2143) (0894dc5) - stdlib: Add
isFinite
,isClose
,sin
,cos
,tan
to Float32 (#2168) (bdb4641) - stdlib: Add
isFinite
,isClose
,sin
,cos
,tan
to Float64 (#2166) (fa728d2) - stdlib: Add
List.filterMap
,List.filterMapi
,List.findMap
(#2201) (551f5ad) - stdlib: add
Path.removeExtension
(#2226) (7b7acfd) - stdlib: Add
Path.updateExtension
(#2282) (6d795d0) - stdlib: Add
String.repeat
toString
module (#2140) (6c33d08) - stdlib: Add
toList
,fromList
,toArray
,fromArray
to Stack (#2198) (b815bcd) - stdlib: Add an
Ascii
submodule toChar
and moveisAscii
,toUppercase
,toLowercase
(#2178) (328cf01) - stdlib: Add user-friendly file system module (#1966) (c4f638e)
- stdlib: Implement
reinterpret
between float and int values (#2257) (e3a4eac) - stdlib: Json value access utils (#2150) (72cc978)
- stdlib: Optimize
List.init
to support large lists (#2249) (3de64ba) - stdlib: Reimplement
Number.gamma
andNumber.factorial
(#2182) (1e5f921) - stdlib: Reimplement
Number.sin
,Number.cos
,Number.tan
(#2158) (f97c011) - stdlib: Seeded hashing (#2170) (ce872ab)
Bug Fixes
- cli: Only accept
--dir
,--env
ongrain run
orgrain
(#2279) (0d249dc) - compiler: Correct
in_function
state when typing record properties (#2205) (d9dd274) - compiler: Correct
Include_module_name_mismatch
error (#2261) (ef77a31) - compiler: Correct location of parmatch mismatch type error (#2259) ([eb85692](ht...
compiler: v0.7.0
0.7.0 (2025-04-26)
⚠ BREAKING CHANGES
- cli: Require node
>=22.13
(#2256) - compiler: Disallow whitespace for negative literals + allow infix operators on new line (#2136)
- compiler: Custom Grain object files (#2104)
- Remove
->
token in favor of=>
(#2177) - stdlib: Seeded hashing (#2170)
- stdlib: Add an
Ascii
submodule toChar
and moveisAscii
,toUppercase
,toLowercase
(#2178)
Features
- Add
getAll
,setAll
,removeAll
toList.Associative
(#2224) (9c49a23) - compiler: Custom Grain object files (#2104) (4b56c53)
- compiler: Deduplicate foreign imports (#2233) (e8a3ed2)
- compiler: Disallow whitespace for negative literals + allow infix operators on new line (#2136) (3186155)
- compiler: Enable single-file compilation (#2105) (824b365)
- compiler: Improve exhaustive warning for lists (#2220) (f54dbdf)
- compiler: Use location for
Unbound_label_with_alt
error (#2196) (271d7cb) - compiler: Use program location for
_gmain
(#2231) (bdbbd05) - fmt: Add trailing comma on inline records (#2266) (cbe12e2)
- lsp: Add or remove block braces code action (#2222) (3134504)
- Remove
->
token in favor of=>
(#2177) (d0038d3) - runtime: Optimize
==
for lists (#2247) (1cba005) - runtime: Prevent stack overflow while collecting large lists (#2248) (097ae7d)
- stdlib:
List.Associative
Submodule (#2202) (fbb08bf) - stdlib: Add
**
toFloat64
andFloat32
(#2163) (7542d92) - stdlib: Add
Array.tryInit
(#2209) (218ff78) - stdlib: Add
Bytes.setChar
andBytes.getChar
(#2215) (4919ba3) - stdlib: Add
Char.encodedLength
(#2238) (c549fac) - stdlib: Add
copySign
,sqrt
,min
,max
,round
,trunc
,floor
,ceil
toFloat32
(#2161) (f5a3dd3) - stdlib: Add
copySign
,sqrt
,min
,max
,round
,trunc
,floor
,ceil
toFloat64
(#2162) (e99dcba) - stdlib: Add
Exception.toString
(#2143) (0894dc5) - stdlib: Add
isFinite
,isClose
,sin
,cos
,tan
to Float32 (#2168) (bdb4641) - stdlib: Add
isFinite
,isClose
,sin
,cos
,tan
to Float64 (#2166) (fa728d2) - stdlib: Add
List.filterMap
,List.filterMapi
,List.findMap
(#2201) (551f5ad) - stdlib: add
Path.removeExtension
(#2226) (7b7acfd) - stdlib: Add
Path.updateExtension
(#2282) (6d795d0) - stdlib: Add
String.repeat
toString
module (#2140) (6c33d08) - stdlib: Add
toList
,fromList
,toArray
,fromArray
to Stack (#2198) (b815bcd) - stdlib: Add an
Ascii
submodule toChar
and moveisAscii
,toUppercase
,toLowercase
(#2178) (328cf01) - stdlib: Add user-friendly file system module (#1966) (c4f638e)
- stdlib: Implement
reinterpret
between float and int values (#2257) (e3a4eac) - stdlib: Json value access utils (#2150) (72cc978)
- stdlib: Optimize
List.init
to support large lists (#2249) (3de64ba) - stdlib: Reimplement
Number.gamma
andNumber.factorial
(#2182) (1e5f921) - stdlib: Reimplement
Number.sin
,Number.cos
,Number.tan
(#2158) (f97c011) - stdlib: Seeded hashing (#2170) (ce872ab)
Bug Fixes
- compiler: Correct
in_function
state when typing record properties (#2205) (d9dd274) - compiler: Correct
Include_module_name_mismatch
error (#2261) (ef77a31) - compiler: Correct location of parmatch mismatch type error (#2259) (eb85692)
- compiler: Correct type approximation on recursive functions (#2154) (b0fb040)
- compiler: Fix 'inconsistent assumptions over interface' bug (#2253) (66e5929)
- compiler: Handle non-exhaustive record patterns (#2274) (0431e74)
- compiler: Prevent impossible string error from pattern matching (#2218) ([a1caf87](https://github.com/grain...