Releases: crystal-lang/crystal
Releases · crystal-lang/crystal
1.17.1
Bugfixes
tools
- (docs-generator) [regression] Revert "Handle doc locations when file is in parent directory" (#15996, thanks @Blacksmoke16)
Infrastructure
- Changelog for 1.17.1 (#16009, thanks @straight-shoota)
1.17.0
Breaking changes
stdlib
- Make
Colorize.on_tty_only!
the default behavior (#15881, thanks @HertzDevil) - (concurrency) Rename execution contexts + improve their docs (#15936, thanks @ysbaddaden)
- (files) Refactor
IO.pipe
blocking mode (#15823, thanks @ysbaddaden) - (files) Fix: set
IO::Stapled.pipe
blocking args to nil, as perIO.pipe
(#15925, thanks @ysbaddaden) - (networking) Refactor
Socket
blocking mode (#15804, thanks @ysbaddaden) - (runtime) Let the event loop decide the blocking mode of
File
(#15930, thanks @ysbaddaden) - (serialization) Fix: libxml manual memory management (#15906, #15933, thanks @ysbaddaden)
- (system) Turn
SystemError.from_errno
into a macro (#15874, thanks @straight-shoota)
Features
lang
- (macros) Handle properly stringifying single line blocks (#15568, thanks @Blacksmoke16)
- (macros) Handle properly stringifying multiline named tuple literals (#15566, thanks @Blacksmoke16)
- (macros) Handle properly stringifying multiline calls (#15691, thanks @Blacksmoke16)
- (macros) Handle significant whitespace before a blocks body (#15692, thanks @Blacksmoke16)
- (macros) Support
{% if ...; end; ... %}
macro expressions (#15917, thanks @HertzDevil) - (macros) Support
{% elsif %}
when stringifyingMacroIf
nodes (#15928, thanks @HertzDevil)
stdlib
- Add
Colorize.default_enabled?
(#15912, thanks @HertzDevil) - [experimental] Add
Struct.pre_initialize
(#15896, thanks @HertzDevil) - (files) Support Windows local device paths in
Path
(#15590, thanks @HertzDevil) - (llvm) Support LLVM 21.0 (development branch) (#15771, thanks @HertzDevil)
- (networking) Extract
WebSocket#do_ping
,#do_close
helper methods for overrides (#15545, thanks @luislavena) - (networking) Add support for IPv6 scoped addresses (RFC4007) (#15263, thanks @foxxx0)
- (networking) Expose
HTTP::Request#uri
(#15816, thanks @syeopite) - (numeric) Add
BigRational#to_i
(#15809, thanks @HertzDevil) - (numeric) Add
Float::Primitive#sign_bit
(#15830, thanks @HertzDevil) - (runtime) Add explicit
Crystal::EventLoop#reopened(FileDescriptor)
hook (#15640, thanks @ysbaddaden) - (runtime) Add
Crystal::EventLoop::FileDescriptor#open
(#15750, thanks @ysbaddaden) - (runtime) Add
Thread::Local(T)
(#15616, thanks @ysbaddaden) - (serialization) Add
XML.libxml2_version
(#15623, thanks @straight-shoota) - (serialization) Add
YAML::Builder#start_document(*, implicit_start_indicator)
(#15835, thanks @straight-shoota) - (serialization) Support pretty printing of
XML
types (#15833, thanks @HertzDevil) - (serialization) Expose error message from libyaml on emitter errors (#15841, thanks @straight-shoota)
- (serialization) Add
Path.from_json_object_key
(#15877, thanks @jneen) - (serialization) Add
Time::Location#{to,from}_{json,yaml}
(#15939, thanks @Sija) - (serialization) Extract
XML::Document
fromXML::Node
(#15920, thanks @ysbaddaden) - (text) [experimental] Add
Crystal::System.wstr_literal
on Windows (#15747, thanks @HertzDevil) - (text) Add
String#ensure_suffix
andString#ensure_prefix
(#15782, thanks @MatheusRich) - (text) Add
truncate_at_null
parameter toString.new(Bytes)
and.from_utf16
(#15887, thanks @HertzDevil) - (time) Add
Time.month_week_date
(#15620, thanks @HertzDevil) - (time) Improve the TZif database file parser (#15825, thanks @HertzDevil)
- (time) Support POSIX TZ environment variable strings (#15792, thanks @HertzDevil)
- (time) Improve whitespace handling in
Time::Format
(#15890, thanks @HertzDevil) - (time) Support Windows system time zone transitions in all years (#15891, thanks @HertzDevil)
- (time) Support POSIX TZ strings in TZif databases (#15863, thanks @HertzDevil)
compiler
- (cli) Support
--x86-asm-syntax
for emitting Intel style assembly (#15612, thanks @HertzDevil) - (debugger) Support debug info of 128-bit enum members (#15770, thanks @HertzDevil)
- (parser) More robust trailing expressions newline implementation (#15614, thanks @Blacksmoke16)
- (parser) Handle properly stringifying multiline (boolean) expressions (#15709, thanks @Blacksmoke16)
- (parser) Stringify
MacroIf
unless
nodes properly (#15919, thanks @HertzDevil) - (parser) Support
elsif
when stringifyingIf
nodes (#15918, thanks @HertzDevil) - (parser) Add location info to
MacroVar
nodes (#15947, thanks @Blacksmoke16) - (semantic) Improve error message for
pointerof
(#15876, thanks @straight-shoota)
tools
- Macro code coverage tool (#15738, thanks @Blacksmoke16)
- (docs-generator) Limit paragraph
max-width
in API docs (#15672, thanks @straight-shoota)
Bugfixes
lang
- [experimental] Do not use private linkage for slice literal buffers (#15746, thanks @HertzDevil)
stdlib
- Require
NO_COLOR
to be non-empty ([#15880], thanks @HertzDevil) - (benchmark) Use
UInt64
to track iteration count during warm-up calculation inBenchmark::IPS
([#15780], thanks @syeopite) - (collection) Fix
Array#|
for different item types ([#15756], thanks @straight-shoota) - (concurrency) Fix calling
Fiber::ExecutionContext#enqueue
from bareThread
([#15767], thanks @ysbaddaden) - (concurrency) Simplify
Crystal::System::Fiber::RESERVED_STACK_SIZE
initializer on Windows ([#15820], thanks @HertzDevil) - (concurrency) Do not print adjacent nodes in
Thread::LinkedList#inspect
([#15829], thanks @HertzDevil) - (files) Fix async append to file in IOCP ([#15681], thanks @ysbaddaden)
- (numeric) [regression] Fix
BigFloat#format
not compiling ([#15796], thanks @HertzDevil) - (numeric) Never output exponent in
BigDecimal#format
([#15795], thanks @HertzDevil) - (numeric) Preserve precision when passing
BigDecimal
orBigFloat
tosprintf
%i
([#15808], thanks @HertzDevil) - (numeric) Fix
Float32#abs
for signed zeros ([#15814], thanks @HertzDevil) - (numeric) Ensure unary
Float32#-
andFloat64#-
flip sign bit ([#15857], thanks @HertzDevil) - (runtime) reopen async
File
passed toProcess.exec
and.run
(win32) ([#15703], thanks @ysbaddaden) - (runtime) raise on manual fiber resume from sleep ([#15744], thanks @ysbaddaden)
- (runtime) race condition in
Fiber::ExecutionContext::Isolated#wait
([#15872], thanks @ysbaddaden) - (runtime) Prevent leaking memory when
exec_recursive
's block r...
1.16.3
Bugfixes
stdlib
- (runtime) Fix
Crystal::EventLoop::LibEvent
andFiberExecutionContext
integration (#15759, backported from #15743, thanks @ysbaddaden)
compiler
- (codegen) Add fallback if
__crystal_raise_cast_failed
is missing (#15769, backported from #15762, thanks @HertzDevil) - (semantic) [regression] Remove type binding on
T
forPointer(T)#value=
(#15757, backported from #15751, thanks @HertzDevil)
Infrastructure
- Changelog for 1.16.3 (#15758, thanks @straight-shoota)
1.16.2
Bugfixes
stdlib
- (numeric) Fix show
unit_separator
in#humanize_bytes
with empty prefix (#15717, backported from #15683, thanks @straight-shoota) - (runtime)
CRYSTAL_LOAD_DEBUG_INFO=1
fails with-Dexecution_context
(#15715, backported from #15704, thanks @ysbaddaden) - (runtime) Fix
-Dtracing
raises math overflows on fiber sleep (#15725, backported from #15722, thanks @ysbaddaden) - (runtime) Fix
Fiber::ExecutionContext::Isolated#wait
must suspend fiber (#15723, backported from #15720, thanks @ysbaddaden) - (runtime) Fix run win32 console reader in bare thread (#15726, backported from #15724, thanks @ysbaddaden)
compiler
- (semantic) Do not add
ReferenceStorage
toValue
's subclasses twice (#15718, backported from #15706, thanks @HertzDevil)
Refactor
compiler
- (codegen) Add
__crystal_raise_cast_failed
for non-interpreted code (#15712, backported from #15708, thanks @HertzDevil)
Infrastructure
- Changelog for 1.16.2 (#15716, thanks @straight-shoota)
- (ci) Fix package shards on MinGW (#15719, thanks @straight-shoota)
- (ci) Only set up Cygwin on Windows CI if truly required (#15713, backported from #15661, thanks @HertzDevil)
1.16.1
Bugfixes
stdlib
- (runtime) Correctly transfer FD ownership in polling event loop (#15650, thanks @ysbaddaden)
- (runtime) Fix error message when
PollDescriptor
can't transfer fd (#15663, thanks @ysbaddaden) - (runtime) Fix
libgc
pkg-config name for version discovery (#15636, thanks @straight-shoota) - (serialization) [regression] Fix link
bcrypt
withlibxml2
on Windows (#15651, thanks @straight-shoota)
compiler
- (cli) [regression] Fix
crystal eval
read from stdin (#15655, thanks @straight-shoota)
Documentation
stdlib
- (runtime) Enable docs for
ExecutionContext
(#15644, thanks @straight-shoota) - (runtime) Fix mark method overrides on
ExecutionContext
as:nodoc:
(#15659, thanks @ysbaddaden) - (runtime) Update docs for
Fiber::ExecutionContext.default_workers_count
(#15664, thanks @ysbaddaden) - (runtime) Enhance documentation for
ExecutionContext
(#15665, thanks @straight-shoota)
Infrastructure
- Changelog for 1.16.1 (#15666, thanks @straight-shoota)
1.16.0
Features
lang
- Support
Slice.literal
in the interpreter (#15531, thanks @HertzDevil) - Support
Slice.literal
with inferred element type (#15529, thanks @HertzDevil) - (macros) Error on
TypeNode#instance_vars
,#has_inner_pointers?
macros in top-level scope (#15293, thanks @straight-shoota) - (macros) Support
sizeof
andalignof
inside macros for stable types (#15497, thanks @HertzDevil)
stdlib
- Fix
Box(Pointer).box
to not allocate pointer storage on the heap (#15562, thanks @ysbaddaden) - (collection) Add
Indexable#find
and#find!
(#15552, #15589, thanks @punteek, @Sija) - (llvm) Add
LLVM.version
(#15354, thanks @straight-shoota) - (llvm) Support LLVM 20 (#15412, #15418, thanks @HertzDevil, @straight-shoota)
- (llvm) Add
LLVM.init_native_target
andLLVM.init_all_targets
(#15466, thanks @HertzDevil) - (llvm) Support
$LLVM_VERSION
,$LLVM_TARGETS
, and$LLVM_LDFLAGS
(#15091, thanks @HertzDevil) - (llvm) Add
LLVM::CodeModel::Tiny
(#15608, thanks @HertzDevil) - (macros) Implement
StringLiteral#scan
(#15398, thanks @homonoidian) - (networking) Add
Path
as possible argument type toUNIXSocket
andUNIXServer
(#15260, thanks @BigBoyBarney) - (networking) Add
Cookies#==
(#15463, thanks @straight-shoota) - (runtime) Add
EventLoop#wait_readable
,#wait_writable
methods methods (#15376, thanks @ysbaddaden) - (runtime) Initialize
Fiber
with an explicit stack (#15409, thanks @ysbaddaden) - (runtime) Add fiber queues for execution context schedulers (#15345, thanks @ysbaddaden)
- (runtime) RFC 2: Skeleton for ExecutionContext (#15350, #15596, thanks @ysbaddaden)
- (runtime) RFC 2: Add
Fiber::ExecutionContext::SingleThreaded
scheduler (#15511, thanks @ysbaddaden) - (runtime) RFC 2: Add
Fiber::ExecutionContext::Isolated
(#15513, thanks @ysbaddaden) - (runtime) RFC 2: Add
Fiber::ExecutionContext::Monitor
(#15599, thanks @ysbaddaden) - (runtime) RFC 2: Add
Fiber::ExecutionContext::MultiThreaded
(#15517, thanks @ysbaddaden) - (serialization) Add
Union.from_json_object_key?
(#15411, thanks @straight-shoota) - (system) Add
Process::Status#description
(#15468, thanks @straight-shoota) - (text) Add
IO
overloads toChar#upcase
,#downcase
,#titlecase
(#15508, thanks @HertzDevil) - (text) [breaking] New algorithm for
File.match?
(#15607, thanks @straight-shoota)
compiler
- (cli) Support
--output
long option incrystal build
(#15519, thanks @HertzDevil) - (cli) Support directory name in
--output
CLI option (#15471, thanks @straight-shoota) - (cli) [breaking] Add compiler path to
$PATH
and$CRYSTAL_EXEC_PATH
for subcommands (#15186, thanks @straight-shoota) - (cli) Respect
--mcpu=help
in the compiler (#15595, thanks @HertzDevil) - (cli) Add
CRYSTAL_EXEC_PATH
tocrystal env
[followup #15186] (#15632, thanks @straight-shoota) - (codegen) Set linkage of
__crystal_*
funs to internal (#15439, thanks @ysbaddaden) - (codegen) Add function name to
CRYSTAL_DEBUG_CODEGEN
log helper (#15506, thanks @HertzDevil) - (parser) Handle properly stringifying multiline macro expressions (#15305, thanks @Blacksmoke16)
- (parser) [breaking] Check that def, macro, and block parameters don't end with
?
or!
(#12197, thanks @potomak)
tools
- (docs-generator) Add docs to enum member helper methods (#15379, thanks @nobodywasishere)
- (docs-generator) Add
:showdoc:
directive forprivate
andprotected
objects (RFC #11) (#15337, thanks @nobodywasishere) - (docs-generator) Add documentation support for
lib
,fun
,union
,cstruct
,external
, andtype
(RFC #11) (#15447, thanks @nobodywasishere)
Bugfixes
stdlib
- (collection) Fix hash
@indices
can grow larger thanInt32::MAX
bytes (#15347, thanks @ysbaddaden) - (collection) Fix
Tuple#to_a(&)
for arbitrary block output type (#15431, thanks @straight-shoota) - (collection) Fix
Range#size
for unsigned edge cases (#14978, thanks @straight-shoota) - (collection) [breaking] Fix the return type of
Enumerable#sum
,#product
for union elements (#15314, thanks @rvprasad) - (concurrency) Fix
Reference#exec_recursive
,#exec_recursive_clone
to be fiber aware (#15361, thanks @ysbaddaden) - (concurrency) RFC 2: MT safe fiber context switch on ARM (#15582, thanks @ysbaddaden)
- (crypto) Fix argument type for
EVP_CIPHER_get_flags
(#15392, thanks @miry) - (files) Never remove UNC share name in
Path#dirname
(#15583, thanks @HertzDevil) - (files) Fix
File.exists?
for special devices on Windows (#15587, thanks @HertzDevil) - (llvm) Fix LLVM version detection for
-rc1
(#15410, thanks @HertzDevil) - (networking) [breaking] Fix parsing HTTP resource string that looks like absolute URL (#15499, thanks @straight-shoota)
- (runtime) Fix
pkg_config
name forlibgc
bindings on FreeBSD (#15532, thanks @straight-shoota) - (runtime) RFC 2: MT safe fiber context switch on AArch64 (#15581, thanks @ysbaddaden)
- (runtime) Add thread safety to
at_exit
(#15598, thanks @ysbaddaden) - (runtime) Remove top-level calls to
LibGC.has_method?
for backwards compat (#15635, thanks @straight-shoota) - (serialization) Fix
Union.from_yaml
to prioritizeString
for quoted scalar (#15405, thanks @straight-shoota) - (system) signal handler mustn't depend on the event loop (#15325, thanks @ysbaddaden)
- (system) Corrects Windows lib lookup in case-sensitive OSes (#15362, thanks @luislavena)
- (system) Fix permissions application in
File.copy
(#15520, thanks @straight-shoota) - (system) [security] Strip periods, spaces for batch file filtering on Windows (#15573, thanks @GeopJr)
- (system) Extend Windows
Process
completion key's lifetime (#15597, thanks @HertzDevil)
compiler
- (cli) Fix query runtime version of LLVM ([#15355], thanks @straight-shoota)
- (cli)...
1.15.1
Bugfixes
stdlib
- (networking) Disable directory path redirect when
directory_listing=false
(#15393, thanks @straight-shoota) - (runtime) [regression] abstract
EventLoop::Polling#system_add
invalid signature (#15380, backported from #15358, thanks @straight-shoota) - (system) [regression] Fix GC
sig_suspend
,sig_resume
forgc_none
(#15382, backported from #15349, thanks @ysbaddaden)
Documentation
stdlib
- (system) Fix code example in
Process::Status#exit_code
docs (#15381, backported from #15351, thanks @zw963)
Infrastructure
- Changelog for 1.15.1 (#15406, thanks @straight-shoota)
- Update distribution-scripts (#15385, backported from #15368, thanks @straight-shoota)
- Update distribution-scripts (#15388, thanks @straight-shoota)
- Add backports to changelog generator (#15402, thanks @straight-shoota)
- (ci) Add build shards to
mingw-w64
workflow (#15344, thanks @straight-shoota) - (ci) Update shards 0.19.1 (#15384, backported from #15366, thanks @straight-shoota)
- (ci) Add check for shards binary in
test_dist_linux_on_docker
(#15394, thanks @straight-shoota)
1.15.0
Breaking changes
lang
- Allow constants to start with non-ascii uppercase and titlecase (#15148, thanks @nanobowers)
Features
lang
- (macros) Crystal
Not
operators do not need parens for stringification (#15292, thanks @Blacksmoke16) - (macros) Add
MacroIf#is_unless?
AST node method (#15304, thanks @Blacksmoke16)
stdlib
- (collection) Add
Iterator(T).empty
(#15039, thanks @spuun) - (collection) Add
Enumerable#find_value
(#14893, thanks @jgaskins) - (concurrency) Implement the ARM64 Windows context switch (#15155, thanks @HertzDevil)
- (concurrency) Add optional
name
parameter forward toWaitGroup#spawn
(#15189, thanks @spuun) - (crypto) Enable bindings for functions in LibreSSL (#15177, thanks @straight-shoota)
- (log) Add
Log
overloads for logging exceptions without giving a block (#15257, thanks @lachlan) - (networking) Better handle explicit chunked encoding responses (#15092, thanks @Blacksmoke16)
- (networking) Support OpenSSL on MSYS2 (#15111, thanks @HertzDevil)
- (networking) Add
Socket::Address.from
withoutaddrlen
(#15060, thanks @mamantoha) - (networking) Add stringification for
HTTP::Cookie
(#15240, thanks @straight-shoota) - (networking) Add stringification for
HTTP::Cookies
(#15246, thanks @straight-shoota) - (networking) Add
HTTP::Cookie#expire
(#14819, thanks @a-alhusaini) - (numeric) Implement
fast_float
forString#to_f
(#15195, thanks @HertzDevil) - (runtime) Support call stacks for MinGW-w64 builds (#15117, thanks @HertzDevil)
- (runtime) Support MSYS2's CLANGARM64 environment on ARM64 Windows (#15159, thanks @HertzDevil)
- (runtime) Improve
Crystal::Tracing
(#15297, thanks @ysbaddaden) - (runtime) Add
Thread#internal_name=
(#15298, thanks @ysbaddaden) - (runtime) Add
Thread::LinkedList#each
to safely iterate lists (#15300, thanks @ysbaddaden) - (system) Add
Process::Status#exit_code?
(#15247, thanks @straight-shoota) - (system) Add
Process::Status#abnormal_exit?
(#15266, thanks @straight-shoota) - (system) Improve
Process::Status#to_s
for abnormal exits on Windows (#15283, thanks @straight-shoota) - (system) Add
Process::Status#exit_signal?
(#15284, thanks @straight-shoota) - (system) Change
Process::Status#to_s
to hex format on Windows (#15285, thanks @straight-shoota) - (system) Add
Process::Status#system_exit_status
(#15296, thanks @straight-shoota) - (text) Add
Regex::CompileOptions::MULTILINE_ONLY
(#14870, thanks @ralsina) - (text) Add type restrictions to Levenshtein (#15168, thanks @beta-ziliani)
- (text) Add
unit_separator
toInt#humanize
and#humanize_bytes
(#15176, thanks @CTC97) - (text) Add
String#byte_index(Regex)
(#15248, thanks @Zeljko-Predjeskovic) - (text) Add
Colorize::Object#ansi_escape
(#15113, thanks @devnote-dev)
compiler
- Basic MinGW-w64 cross-compilation support (#15070, #15219, thanks @HertzDevil, @BlobCodes)
- (cli) Support building from a MinGW-w64-based compiler (#15077, thanks @HertzDevil)
- (codegen) Add indirect branch tracking (#15122, thanks @ysbaddaden)
- (codegen) Emit position dependent code for embedded targets (#15174, thanks @RX14)
- (interpreter) Support "long format" DLL import libraries (#15119, thanks @HertzDevil)
- (interpreter) Add
cc
's search paths to Unix dynamic library loader (#15127, thanks @HertzDevil) - (interpreter) Basic MinGW-w64-based interpreter support (#15140, thanks @HertzDevil)
- (parser) Add
ECR::Lexer::SyntaxException
with location info (#15222, thanks @nobodywasishere)
tools
- (formatter) Enable pending formatter features (#14718, thanks @Blacksmoke16)
- (unreachable) Implement
codecov
format forunreachable
tool (#15059, thanks @Blacksmoke16)
Bugfixes
lang
- (macros) Add location information to more MacroIf related nodes (#15100, thanks @Blacksmoke16)
stdlib
- LibC bindings and std specs on NetBSD 10 (#15115, thanks @ysbaddaden)
- (files) Treat
WinError::ERROR_DIRECTORY
as an error for non-existent files (#15114, thanks @HertzDevil) - (files) Replace handle atomically in
IO::FileDescriptor#close
on Windows (#15165, thanks @HertzDevil) - (llvm) Fix
find-llvm-config
to ignoreLLVM_CONFIG
's escape sequences (#15076, thanks @HertzDevil) - (log) [regression] Fix
Log
to emit withexception
even if block outputsnil
(#15253, thanks @lachlan) - (macros) Avoid identifier naming collision in
getter
,setter
, andproperty
macros (#15239, thanks @jgaskins) - (networking) [regression] Fix
UNIXSocket#receive
(#15107, thanks @straight-shoota) - (numeric) Fix
Complex#/
edge cases (#15086, thanks @HertzDevil) - (numeric) Fix
Number#humanize
printing of(-)Infinity
andNaN
(#15090, thanks @lachlan) - (runtime) Fix Deadlock with parallel stop-world/fork calls in MT (#15096, thanks @ysbaddaden)
- (runtime) [regression] Protect constant initializers with mutex on Windows (#15134, thanks @HertzDevil)
- (runtime) use
uninitialized LibC::SigsetT
(#15144, thanks @straight-shoota) - (runtime) Fix static linking when using MinGW-w64 (#15167, thanks @HertzDevil)
- (runtime) register GC callbacks inside
GC.init
(#15278, thanks @ysbaddaden) - (runtime) Cleanup nodes in
Thread::LinkedList(T)#delete
(#15295, thanks @ysbaddaden) - (runtime) Make
Crystal::EventLoop#remove(io)
a class method (#15282, thanks @ysbaddaden) - (system) Raise on abnormal exit in
Procss::Status#exit_code
([#15241], thanks @straight-shoota) - (system) Fix
Process::Status
for unknown signals ([#15280], thanks @straight-shoota) - (system) Fix error handling for
LibC.clock_gettime(CLOCK_MONOTONIC)
calls ([#15309], thanks @compumike) - (text) Fix libiconv build on Windows ([#15095], thanks @HertzDevil)
- (text) Change
sprintf "%c"
to support onlyChar
andInt::Primitive
([#15142], thanks @nanobowers) - (time) Fix proper error handling for early end in
HTTP_DATE
parser ([#15232], thanks @straight-shoota)
[#1...
1.14.1
Bugfixes
tools
- (formatter) Handle trailing comma with multiple parameters on the same line (#15097, thanks @Blacksmoke16)
Infrastructure
- Changelog for 1.14.1 (#15323, thanks @straight-shoota)
- (ci) Update XCode 15.3.0 in circleci (#15327, thanks @straight-shoota)
1.14.0
Features
lang
- Allow
^
in constant numeric expressions (#14951, thanks @HertzDevil)
stdlib
- Add support for Windows on aarch64 (#14911, thanks @HertzDevil)
- (collection) [breaking] Add support for negative start index in
Slice#[start, count]
(#14778, thanks @ysbaddaden) - (collection) Add
Slice#same?
(#14728, thanks @straight-shoota) - (concurrency) Add
WaitGroup.wait
andWaitGroup#spawn
(#14837, thanks @jgaskins) - (concurrency) Open non-blocking regular files as overlapped on Windows (#14921, thanks @HertzDevil)
- (concurrency) Support non-blocking
File#read
and#write
on Windows (#14940, thanks @HertzDevil) - (concurrency) Support non-blocking
File#read_at
on Windows (#14958, thanks @HertzDevil) - (concurrency) Support non-blocking
Process.run
standard streams on Windows (#14941, thanks @HertzDevil) - (concurrency) Support
IO::FileDescriptor#flock_*
on non-blocking files on Windows (#14943, thanks @HertzDevil) - (concurrency) Emulate non-blocking
STDIN
console on Windows (#14947, thanks @HertzDevil) - (concurrency) Async DNS resolution on Windows (#14979, thanks @HertzDevil)
- (crypto) Update
LibCrypto
bindings for LibreSSL 3.5+ (#14872, thanks @straight-shoota) - (llvm) Expose LLVM instruction builder for
neg
andfneg
(#14774, thanks @JarnaChao09) - (llvm) [experimental] Add minimal LLVM OrcV2 bindings (#14887, thanks @HertzDevil)
- (llvm) Add
LLVM::Builder#finalize
(#14892, thanks @JarnaChao09) - (llvm) Support LLVM 19.1 (#14842, thanks @HertzDevil)
- (macros) Add
Crystal::Macros::TypeNode#has_inner_pointers?
(#14847, thanks @HertzDevil) - (macros) Add
HashLiteral#has_key?
andNamedTupleLiteral#has_key?
(#14890, thanks @kamil-gwozdz) - (numeric) Implement floating-point manipulation functions for
BigFloat
(#11007, thanks @HertzDevil) - (runtime) Stop & start the world (undocumented API) (#14729, thanks @ysbaddaden)
- (runtime) Add
Pointer::Appender#to_slice
(#14874, thanks @straight-shoota) - (serialization) Add
URI.from_json_object_key?
andURI#to_json_object_key
(#14834, thanks @nobodywasishere) - (serialization) Add
URI::Params::Serializable
(#14684, thanks @Blacksmoke16) - (system) Enable full backtrace for exception in process spawn (#14796, thanks @straight-shoota)
- (system) Implement
System::User
on Windows (#14933, thanks @HertzDevil) - (system) Implement
System::Group
on Windows (#14945, thanks @HertzDevil) - (system) Add methods to
Crystal::EventLoop
(#14977, thanks @ysbaddaden) - (text) Add
underscore_to_space
option toString#titleize
(#14822, thanks @Blacksmoke16) - (text) Support Unicode 16.0.0 (#14997, thanks @HertzDevil)
compiler
- (cli) Adds initial support for external commands (#14953, thanks @bcardiff)
- (interpreter) Add
Crystal::Repl::Value#runtime_type
(#14156, thanks @bcardiff) - (interpreter) Implement
Reference.pre_initialize
in the interpreter (#14968, thanks @HertzDevil) - (interpreter) Enable the interpreter on Windows (#14964, thanks @HertzDevil)
Bugfixes
lang
- Fix
Slice.literal
for multiple calls with identical signature (#15009, thanks @HertzDevil) - (macros) Add location info to some
MacroIf
nodes (#14885, thanks @Blacksmoke16)
stdlib
- (collection) Fix
Range#size
return type toInt32
(#14588, thanks @straight-shoota) - (concurrency) Update
DeallocationStack
for Windows context switch (#15032, thanks @HertzDevil) - (concurrency) Fix race condition in
pthread_create
handle initialization (#15043, thanks @HertzDevil) - (files) [regression] Fix
File#truncate
and#lock
for Win32 append-mode files (#14706, thanks @HertzDevil) - (files) [breaking] Avoid flush in finalizers for
Socket
andIO::FileDescriptor
(#14882, thanks @straight-shoota) - (files) Make
IO::Buffered#buffer_size=
idempotent (#14855, thanks @jgaskins) - (macros) Implement
#sort_by
inside macros usingEnumerable#sort_by
(#14895, thanks @HertzDevil) - (macros) Fix internal error when calling
#is_a?
onExternal
nodes (#14918, thanks @HertzDevil) - (networking) Use correct timeout for
Socket#connect
on Windows (#14961, thanks @HertzDevil) - (numeric) Fix handle empty string in
String#to_f(whitespace: false)
(#14902, thanks @Blacksmoke16) - (numeric) Fix exponent wrapping in
Math.frexp(BigFloat)
for very large values (#14971, thanks @HertzDevil) - (numeric) Fix exponent overflow in
BigFloat#to_s
for very large values (#14982, thanks @HertzDevil) - (numeric) Add missing
@[Link(dll:)]
annotation to MPIR (#15003, thanks @HertzDevil) - (runtime) Add missing return type of
LibC.VirtualQuery
(#15036, thanks @HertzDevil) - (runtime) Fix main stack top detection on musl-libc (#15047, thanks @HertzDevil)
- (serialization) [breaking] Remove
XML::Error.errors
(#14936, thanks @straight-shoota) - (specs) [regression] Fix
Expectations::Be
for module type (#14926, thanks @straight-shoota) - (system) Fix return type restriction for
ENV.fetch
(#14919, thanks @straight-shoota) - (system)
#file_descriptor_close
should set@closed
(UNIX) (#14973, thanks @ysbaddaden) - (system) reinit event loop first after fork (UNIX) (#14975, thanks @ysbaddaden)
- (text) Fix avoid linking
libpcre
when unused (#14891, thanks @kojix2) - (text) Add type restriction to
String#byte_index
offset
parameter (#14981, thanks @straight-shoota)
compiler
- (cli) Add error handling for linker flag sub commands (#14932, thanks @straight-shoota)
- (codegen) Allow returning
Proc
s from top-level funs ([#14917], thanks @HertzDevil) - (codegen) Fix CRT static-dynamic linking conflict in specs with C sources ([#14970], thanks @HertzDevil)
- (interpreter) Fix Linux
getrandom
failure in interpreted code ([#15035], thanks @HertzDevil) - (interpreter) Fix undefined behavior in interpreter mixed union upcast ([#15042], thanks @HertzDevil)
- (semantic) Fix
TopLevelVisitor
adding existingClassDef
type to current scope ([#15067], thanks @straight-shoota)
[#1...