github crystal-lang/crystal 1.11.0

latest releases: 1.14.0, 1.13.3, 1.13.2...
10 months ago

1.11.0 (2024-01-08)

Features

lang

stdlib

compiler

  • (codegen) Add incremental optimization levels (#13464, thanks @kostya)
  • (debugger) Support debug information for 64-bit or unsigned enums (#14081, thanks @HertzDevil)
  • (interpreter) Support instance_sizeof(T) in the interpreter (#14031, thanks @HertzDevil)
  • (interpreter) Support -dynamic.lib in Windows interpreter (#14143, thanks @HertzDevil)
  • (interpreter) Support absolute paths in CRYSTAL_INTERPRETER_LOADER_INFO (#14147, thanks @HertzDevil)
  • (interpreter) Add Crystal::Repl#parse_and_interpret (#14138, thanks @bcardiff)
  • (semantic) Change short_reference for top-level methods to ::foo (#14071, thanks @keshavbiswa)

tools

Bugfixes

stdlib

  • Fix Box(T?) crashing on nil (#13893, thanks @HertzDevil)
  • Fix typos in src (#14053, thanks @kojix2)
  • (collection) Fix Indexable#each_repeated_combination(n) when n > size (#14092, thanks @HertzDevil)
  • (concurrency) Make Process#wait asynchronous on Windows (#13908, thanks @HertzDevil)
  • (concurrency) Fix math overflow after spawning Int32::MAX + 1 fibers (#14096, thanks @ysbaddaden)
  • (concurrency) Fix can't resume a running fiber (#14128, thanks @ysbaddaden)
  • (crypto) Fix OpenSSL error handling for EOF (support for OpenSSL 3.2) (#14169, thanks @straight-shoota)
  • (files) Fix Globber.constant_entry? matching patterns (#13955, thanks @GeopJr)
  • (files) Fix String::Buffer and IO::Memory capacity to grow beyond 1GB (#13989, thanks @straight-shoota)
  • (llvm) Fix a typo (#13914, thanks @kojix2)
  • (numeric) Make String#to_f(whitespace: false) work with infinity and NaN (#13875, thanks @HertzDevil)
  • (numeric) Use LibGMP::SI and UI for size checks, not Long and ULong (#13874, thanks @HertzDevil)
  • (numeric) Fix integral part extraction in Number#format (#14061, thanks @HertzDevil)
  • (numeric) Fix out-of-bounds access in Int128::MIN.to_s(base: 2) (#14119, thanks @HertzDevil)
  • (numeric) Avoid double rounding in Float#format for nonnegative decimal_place (#14129, thanks @HertzDevil)
  • (runtime) Avoid @[ThreadLocal] on Android (#14025, thanks @HertzDevil)
  • (runtime) Never use string interpolation in Crystal::System.print_error (#14114, thanks @HertzDevil)
  • (runtime) Fix segfault with next boehm gc (after v8.2.4) (#14130, thanks @ysbaddaden)
  • (specs) Skip spec execution on error exit (#13986, thanks @straight-shoota)
  • (system) Fix FileUtils.ln_sf to override special file types (#13896, thanks @straight-shoota)
  • (system) Fix Process.exists? throwing errors on EPERM (#13911, thanks @refi64)
  • (system) Fix portable shell command arguments in Process#prepare_args (#13942, thanks @GeopJr)
  • (system) Windows: Do not close process handle in Process#close (#13997, thanks @HertzDevil)
  • (system) Windows: clear Crystal::System::Process#@completion_key after use (#14068, thanks @HertzDevil)
  • (system) Fix UTF-8 console input on Windows (#13758, thanks @erdian718)
  • (text) Fix invalid UTF-8 handling in Char::Reader#previous_char (#14013, thanks @HertzDevil)
  • (text) Fix options parameter for String#split, #scan (#14183, thanks @straight-shoota)
  • (time) Fix time span overflow on Int#milliseconds and Int#microseconds (#14105, thanks @bcardiff)

compiler

  • (cli) Remove unnecessary file check for CLI arguments (#13853, thanks @straight-shoota)
  • (cli) Check for invalid integers in compiler's CLI (#13959, thanks @HertzDevil)
  • (cli) Fix compiler error message for invalid source file (#14157, thanks @straight-shoota)
  • (codegen) Fix a typo in compiler source (#14054, thanks @kojix2)
  • (codegen) Fix codegen error when discarding is_a? or responds_to?'s result (#14148, thanks @HertzDevil)
  • (interpreter) Fix element alignment of Tuple and NamedTuple casts (#14040, thanks @HertzDevil)
  • (interpreter) Crystal::Loader: Skip second linker member on Windows if absent (#14111, thanks @HertzDevil)
  • (parser) Support %r and %x when not followed by delimiter start (#13933, thanks @HertzDevil)
  • (parser) Fix location of global Path nodes in certain constructs (#13932, thanks @HertzDevil)
  • (parser) Fix ToSVisitor for expanded string interpolation in backticks (#13943, thanks @straight-shoota)
  • (parser) Fix location for "invalid trailing comma in call" errors (#13964, thanks @HertzDevil)
  • (semantic) Fix check for file type (#13760, thanks @straight-shoota)
  • (semantic) Fix private type definitions with namespaced Paths (#13931, thanks @HertzDevil)
  • (semantic) Fix missing param count in compilation error message (#13985, thanks @koffeinfrei)
  • (semantic) Fix ReadInstanceVar on typedefs (#14044, thanks @HertzDevil)
  • (semantic) Fix global Path lookup inside macro when def has free variables (#14073, thanks @HertzDevil)
  • (semantic) Add location information to implicit flag enum members (#14127, thanks @Blacksmoke16)

tools

  • (docs-generator) Fix crystal docs check File.exists? for shard.yml (#13937, thanks @straight-shoota)
  • (docs-generator) Fix version sorting in API docs (#13994, thanks @m-o-e)
  • (docs-generator) Strip whitespace in doc comment before determining summary line (#14049, thanks @Blacksmoke16)
  • (docs-generator) Skip Crystal::Macros unless generating docs (#13970, thanks @straight-shoota)
  • (init) Fix tool init error message when target exists but not a dir (#13869, thanks @straight-shoota)
  • (unreachable) Fix infinite recursion of expanded nodes in UnreachableVisitor (#13922, thanks @straight-shoota)

Chores

lang

  • (macros) [deprecation] Deprecate the splat operators in macro expressions (#13939, thanks @HertzDevil)

stdlib

  • (llvm) [deprecation] Deprecate LLVM.start_multithreaded and .stop_multithreaded (#13949, thanks @HertzDevil)

Performance

stdlib

Refactor

stdlib

compiler

tools

Documentation

lang

  • (macros) Add reference to book how merging macro expansion and call docs (#14139, thanks @Blacksmoke16)

stdlib

  • (collection) Fix documentation of Hash#put_if_absent (#13898, thanks @ilmanzo)
  • (collection) Improve docs on initial/default values passed to Array.new and Hash.new (#13962, thanks @straight-shoota)
  • (collection) Improve docs for Iterator step-by-step iteration (#13967, thanks @straight-shoota)
  • (macros) Document Crystal::Macros::MagicConstant (#14070, thanks @HertzDevil)
  • (serialization) Add docs and explicit type restriction for indent parameter of JSON.build (#14140, thanks @syeopite)
  • (text) Add note about Char::Reader's value semantics (#14008, thanks @HertzDevil)
  • (text) Fix documentation for String#index! (#14038, thanks @gettalong)

compiler

Specs

stdlib

compiler

  • (codegen) Remove LLVMExtCreateMCJITCompilerForModule from llvm_ext.cc (#13966, thanks @HertzDevil)
  • (interpreter) Disable mkfifo spec for interpreter (#14051, thanks @HertzDevil)
  • (interpreter) Fix interpreter specs on Windows (#14145, thanks @HertzDevil)

tools

  • (docs-generator) Use top_level_semantic in doc spec instead of semantic (#9352, thanks @makenowjust)

Infrastructure

Don't miss a new crystal release

NewReleases is sending notifications on new releases.