Skip to content

Jule 0.1.3

Latest
Compare
Choose a tag to compare
@mertcandav mertcandav released this 07 Feb 15:30
· 162 commits to master since this release

Language

  • add: map and array literals with explicit type
  • add: assertion casting for dynamic types
  • update: the built-in copy function now uses mutable slicing for destination arrays
  • update: deferred scopes
  • update: trait memory model
  • remove: static constant fields support of impl statements and structures
  • remove: manual memory management options
  • remove: the deprecated directive (see doc comments for deprecation)

Compiler

  • numerous minor fixes, optimizations and improvements
  • fix: thread runtime initialization
  • fix: the != operator equals to the == operator for struct types in the object code
  • fix: code generation for implicit == operator of struct types
  • fix: code generation for trait data of strict type aliases
  • fix: code generation for postfix statements which uses map lookup as lvalue
  • fix: the --opt-deadcode optimizations removes trait methods of structures
  • fix: the --opt-dynamic optimization removes type safety for type casting when optimizing type-match statement case which have a previous case with fall statement
  • fix: code generation for concurrent function calls when parameter count collisions exist
  • fix: initialization of runtime environment data
  • fix: code generation for result data with channel type
  • fix: code generation for raw pointer type metadata of dynamic types
  • fix: code generation for trait virtual table of strict type aliases with smart pointer source type
    • it may cause compilation problems with GCC before the patch (see CI of 261b80d)
  • add: the --opt-zcopy and --opt-zappend optimization flags
  • improve: the --opt-deadcode optimization removes the following statements after empty select statements
  • improve: The --opt-access optimization removes the boundary analysis of expressions like array[i&(len(array)-1)] for arrays whose length is power of two
  • improve: code generation for select statements
  • improve: error messages, with contributions by @adamperkowski (#123)
  • parser: fix nested smart pointer types (like &&int) have nil Token field
  • parser: fix (#119, thanks @puni073 for pointing to the issue) and improve handling of function declarations
  • parser: catch repetitive ignoring of an exceptional like foo()!!!
  • parser: fix scope analysis will generate error for expression which is already logged
  • parser: fix unsafe namespace support of type analysis
  • sema: fix interior mutability analysis for structure copy assignments
  • sema: fix impl statement handling for structures
  • sema: fix strict type alias source type analysis
  • sema: fix mutability and comparable state analysis of types
  • sema: fix type cycle analysis
  • sema: fix map types are not considered as mutable even with mutable key/value type
  • sema: fix map indexing expressions considered lvalue
  • sema: fix analysis and handling indexing support of comptime types
  • sema: fix type inference analysis of untyped slice literals
  • sema: fix analysis of strict type alias structures, and type-enums for casting
  • sema: fix cycle and type analysis of type-enums
  • sema: fix reference handling of scope variables
  • sema: fix type safety analysis of unsafe pointer (*unsafe) type
  • sema: fix mistyped values may cause crash when evaluating sub-ident expressions
  • sema: fix instantiation cycle analysis
  • sema: fix generic type and method evaluation
  • sema: fix expression evaluation allows non-instantiated generic types for sub-ident expressions
  • sema: fix generic type analysis does not supports nested generic type instantiation
  • sema: fix generic type analysis of generic define coming from different package
  • sema: add responsive expression support for map indexing
  • sema: add casting support for traits
  • sema: catch unsafe pointer (*unsafe) type for invalid dynamic generic type annotations

Standard Library

  • add: std/html
  • add: std/net/url
  • add: std/path
  • all: refactoring and rehandling with breaking changes
  • runtime: fix the string conversion algorithm tries to call Str(self)!: str methods like reserved Str(self): str methods
  • runtime: fix sema queue implementation (affects sync::Mutex, sync::WaitGroup, and new sync::RWMutex)
  • runtime: fix map lookup does not set to default value if record is not exist (#129)
  • runtime: fix blocking-select statement may cause deadlock panic even for no-deadlock cases
  • runtime: update hashing algorithm and optimize map implementation
  • std/conv: rename the ConvError as Conv
  • std/conv: remove the Ok field of Conv
  • std/encoding/json: fix custom encoding and decoding method detection
  • std/jule/sema: rename Value as ValueSym
  • std/jule/sema: rename Data as Value
  • std/jule/sema: rename the Value field as ValueSym of Var and EnumItem
  • std/jule/sema: rename the Data field as Value of ValueSym
  • std/jule/sema: rename the Datas field as Values of TupleExpr
  • std/mem: remove Free and Heap
  • std/strings: add theReplacer struct
  • std/sync: add RWMutex
  • std/unicode/utf16: remove MaxRune
  • std/unicode/utf16: add RuneLen

API

  • remove: deferred scope API
  • remove: jule::Trait
  • jule::Str: remove std::basic_string support (#121, thanks @puni073 for pointing to the issue)

Legacy Support

Jule 0.1.3 includes critical bug fixes, and updating is highly recommended. However, this update may require additional effort. It introduces some breaking changes and modifications that could alter behavior, potentially making debugging more difficult. There are significant additions and removals in the API and standard library. Compiled programs may not behave as expected.