Language
- add: 3-index slicing
- add: type assertion
- update: range iteration behavior of strings
- update: use arbitrary-big numbers for untyped constants
- update: floating-point division behavior
- update: casting works different for dynamic types
- update: type aliases are not considered cycle-risky for type aliases
- update: allow strict type aliases to type any for type enums
- update: strict type aliases to type-enum will not be inherited
- rename:
SmallestNonZero
static field asSmallestNonzero
of thef64
andf32
- remove: named field support of type-enums
Compiler
- numerous optimizations, fixes, and improvements
- fix: code generation for casting expressions from dynamic type to implicitly smart pointer types such as maps and channels
- fix: code generation of trait virtual table for implicitly smart pointer types such as maps and channels
- fix: code generation of dynamic type data for implicitly smart pointer types such as maps and channels
- fix: code generation will not generate iteration break-point for
for in []rune(s)
iterations when--opt-iter
optimizations enabled - fix: code generation may be failed for declarative multi-assign expressions if
--opt-assign
optimizations enabled - fix: the
--opt-zcopy
and--opt-zappend
optimizations may cause compile issues - fix: integer wrap around behavior might not be implemented in IR and might compile with undefined behavior
- fix: code generation for array comparisons
- fix: the
--opt-math
optimizations may apply wrong optimizations - fix: code generation for exceptional handler scopes with no use declaration
- fix: location information handling for error messages
- (windows) fix: compiler does not adds
.exe
extension if it is missing - (windows) fix: LTO support for Clang (it may cause compile errors with not-MinGW Clang)
- add:
tool targets
command - update: catch invalid target pairs and complain with error
- token: fix carriage-return characters may cause infinite loop when tokenizing string literals
- token: fix
Fileset.GetRow
ignores final lines with no new-line - parser: fix function with errors may cause crash
- parser: reused directive causes errors instead of ignoring silently
- parser: fix unary operator handling of binary expressions
- parser: fix missing expressions in brace literal may cause crash instead of compiler error
- sema: untyped constant literals allowed in Safe Jule for binded types
- sema: fix value type determination may ignore the strict type alias sources when evaluation of array and structure literals
- sema: fix evaluation of binary expressions for
comptimeTypeInfo
- sema: fix owner define will not reference to the struct if it used via type alias when evaluating expression
- sema: fix type-enums are not considered as mutable types
- sema: fix global variable referencing a function may cause crash due to analysis issue
- sema: fix and improve package analysis
- sema: fix implicit casting handling of the
error
calls - sema: fix type compatibility checking for constant floating-point expressions
- sema: fix type compatibility checking may ignore whether type is strict type alias for functions
- sema: fix responsive type handling of the built-in append function
- sema: fix reference collection for types referenced from eval
- sema: fix handling of comparable array types
- sema: fix checking of the reserved main and initializer function signatures
Standard Library
- add: std/errors
- (windows) all: all MinGW dependencies are removed, standard library uses Windows API
- all: error handling model updated to latest recommended style
- (windows) runtime: fix #107
- runtime: fix deadcode analysis for mutexes
- runtime: fix the built-in
make
function does not initialize all capacity (#133) - runtime: fix the built-in
append
function does not initialize all capacity if a new slice allocated (#134) - runtime: fix the runtime string conversion function cannot handle reserved
Str
functions of can-nil types - runtime: smart pointer types supports using of element’s reserved
Str
function - std/conv: reimplement
- std/jule/types: reimplement
- std/math/cmplx: reimplement
- std/os: reimplement
- std/bufio: add
Scanner.EOF
- std/bytes: the split functions limits capacity of parts to its length
- std/comptime: remove
Kind
(fields remain as constant variables) - std/encoding/csv: rename
Writer.UseCrlf
asWriter.UseCRLF
- std/encoding/json: fix
Valid
function reports false for some JSON inputs with spaces - std/encoding/json: fix
DecodeJSON
reserved decoder function does not supports JSON objects or arrays - std/encoding/json: numerous minor fixes and improvements
- std/encoding/json: fix
Decode
function throws UnexpectedToken error if JSON input have trailing spaces - std/encoding/json: fix invalid token may cause panic while decoding array or object (with map type)
- std/encoding/json: fix invalid token case may be reported with
DecodeError.InvalidValue
instead ofDecodeError.InvalidToken
while decoding object (with struct type) - std/encoding/json: fix invalid key may cause panic while decoding map
- std/encoding/json: add
Value
,Object
,Array
,Bool
,Number
, andString
- std/encoding/json: add dynamic decoding support
- std/math: minor fixes
- std/math: rename
NextAfter32
asNextafter32
- std/math: rename
NextAfter
asNextafter
- std/math: rename
F64Bits
asF64bits
- std/math: rename
F32Bits
asF32bits
- std/math: rename
F64frombits
asF64frombits
- std/math: rename
F32frombits
asF32frombits
- std/math/big: rename Int.BitNot as Int.Not
- std/math/big: update
Int.Parse
definition and behavior - std/math/big: add
Accuracy
,Int.F64
- std/math/big: fix
Int.Parse
does not catch invalid separators - std/io: add
ReaderAt
,WriterTo
,Seeker
,WriteStr
,ReadAll
,LimitReader
,SeekStart
,SeekCurrent
,SeekEnd
,Copy
,CopyBuffer
, andDiscard
,ErrShortWrite
,ErrShortBuffer
,ErrUnexpectedEOF
,ErrNoProgress
- std/jule/ast: remove
SubIdentType
- std/jule/ast: add
TypeAssertionExpr
- std/jule/sema: remove
TypeEnumItem.Ident
- std/jule/sema: add
Type.SoftStruct
,TypeAssertionExpr
- std/jule/sema: remove
TypeEnumItem.Ident
,TypeEnumItem.FindItem
- (windows) std/os: fix long path support after Windows 10.0.15063
- std/os/filepath: update sign of
Abs
- std/os/filepath: add
SplitList
- std/slices: rename
Find
asIndex
,FindLast
asIndexLast
- std/strings: add
Reader
- std/sys: reimplement
Errno
and relevant functions - std/testing: add
T.Logf
- std/unicode: add
In
,IsPrint
API
- remove:
jule::nil
,jule::MAX_32
,jule::MIN_F32
,jule::MAX_F64
,jule::MIN_F64
,jule::MAX_I64
,jule::MIN_I64
,jule::MAX_U64
variables - remove: the
jule::print
,jule::println
,jule::append
,jule::__append
,jule::copy
,jule::__copy
functions - add: the
__jule_print
, and__jule_println
functions - fix: slicing error gives length instead of capacity for capacity information
Legacy Support
This version is incompatible with source code written for previous versions, including Jule 0.1.3. Older compiler versions cannot compile this version’s standard library and existing source code may need to be adapted for the new version.
The most common potential issues:
- Incompatibilities with the new error handling standard
- Using dynamic types
- Renaming and reimplementations on the standard library
- Unexpected behavior in range iterations with strings