Skip to content
This repository has been archived by the owner on Nov 29, 2023. It is now read-only.

0.2.0 Stable

Latest
Compare
Choose a tag to compare
@l1mey112 l1mey112 released this 02 Dec 13:01
· 4 commits to master since this release

Release Changelog Complete Post - stas 0.2.0

Changelog

This is the first stable release of stas. FreeBSD and Linux are supported in their entirety. The new include system, conditional compilation, and symlink sub command allow stas to be used outside of the supporting repository directory.

The language and compiler have become stable and user friendly, and the development of stas will slow down from this point onward.

Thank you for sticking around!

  • Native FreeBSD support.
  • FreeBSD is now a cross compilation target specified using the -os switch.
  • Compile time conditional compilation using the comptime keyword.
  • -os freebsd declares TARGET_FREEBSD and -os linux declares TARGET_LINUX
  • ?def keyword is used to check if a constant variable is declared.
  • All POSIX OS specific system calls and definitions are declared seamlessly using conditional compilation.
  • Basic C FFI interface using the cextern keyword. C FFI is limited to freestanding libraries.
  • -c switch to allow creation of object code only, for use with linking to C programs.
  • Inline assembly.
  • syscall0 to syscall6 and _breakpoint keywords have been removed from stas, now implemented with inline assembly.
  • All command line argument switches have been standardised to use only one dash. For example, -dump-tok and -trace-calls.
  • -unsafe compiler switch, currently only strips assertions.
  • Pure functions using the const qualifier before a function declaration. Const functions can be used inside constant expressions and be evaluated at compile time.
  • Add -comptime-depth switch for limiting recursion when evaluating compile time constant functions, default is 12.
  • Better inclusion/module system.
  • Files included with the include 'file.stas' will be searched for in the current directory of the current stas file.
  • Files included with the include <file.stas> form will be searched for in the stas library folder, next to the stas compiler executable, located in lib/.
  • ./stas symlink sub command. Creates a symbolic link to the stas executable in /usr/local/bin to allow it to be invoked from anywhere.
  • Files may only be included once. Similar to #pragma once.
  • Wyrand PRNG is used for rand. A hash library is included to store Wyrand hash functions.
  • OS indepentent way to create localhost POSIX TCP sockets in the standard library.
  • Support for syscall errno values and handling using the errno? function.
  • Stack based allocation buffer now uses a static buffer.
  • Add functions inside the term.stas library for colouring text.
  • Implementation many string manipulation functions inside the standard library.
  • Many OS independent functions for interfacing with child processes, files, file paths, file descriptors and more have been implemented.
  • execute_child? get_executable_path find_abs_path_of_executable? and normalise_path are among the many OS independent functions implemented.
  • Updated old APIs in the standard library to use the fn optional? semantics.
  • Outdated examples have been updated to use OS independent APIs.
  • Many examples and tests cases have been added to the stas repository. Try some!
  • Assembly files generated by the stas backend will reside in /tmp/stas as to not clog up your working directory.
  • Bugfix: the linker is properly called when generating object files.
  • Bugfix: noreturn based parser fixes.
  • Plus many undocumented bugfixes trailing along with commits.