Fuzion Logo
fuzion-lang.dev — The Fuzion Language Portal
JavaScript seems to be disabled. Functionality is limited.

2023-09-15: Fuzion September Update

Here is this month's update:

Even though August was a holiday month for the entire Fuzion team, many exciting things have happened.

The largest change was the addition of a first experimental version of the JVM bytecode backend (#1854), which brings an enormous performance boost compared to the interpreter.

A summary of the most important changes:

  • Fuzion language
    • flag error when assigning choice element to this type of type feature: #1793.

  • front end
    • handle boxing of erroneous and empty values gracefully, fixes a user-visible exception when compiling errorneous code: #1795.

    • parser: allow closing brace of formal args list at min indent, #1803.

    • an error is produced if a field is added to a primitive type like i32, this used to cause a crash in the backend: #1808.

    • improved backward type propagation for arrays, #1814.

      This means that

      
          a array i32 := []
                
      works as expected, whereas previously the right side would have type array void resulting an in incompatible type error.

    • fixed a regression which broke the lookup of nontype features that match a type name which led to poor error messages: #1826.

    • introduced an explicit error message when using a choice type as a constraint for a type parameter: #1836.

    • Allow result type in declaration using => #1890.

      This means that

      
          foo i32 => 42
                
      is now a valid feature declaration, and this syntax will eventually replace the is syntax for feature declarations.

  • fz command
    • for -effects option, added check if used effect is instantiated: #1916.

  • JVM back end
  • added first, incomplete version of a JVM bytecode backend (#1848, #1854) and first bug fixes (#1883, #1885, #1887, #1891, #1892, #1896, #1897, #1901, #1905, #1909, #1910, #1923, #1924, #1927).

    There are two new options to the fz command:

    • -jvm creates class files and immediately loads them via a ClassLoader and executes the code, similar to -interpreter, and
    • -classes that creates a directory fuzion_generated_classes that contains class files.

    Biggest restrictions right now

    • Only part of the intrinsics are implemented
    • value types are not copied when assigned such that they have reference semantics.
    • no threads
    • no abort for effects
    • many other minor things, many marked with NYI in the sources
  • interpreter
    • fix tanh intrinsic: #1868.

  • base library
    • The atan2 feature for floating point numbers is now implemented in pure Fuzion. This was necessary due to differences in the implementation of atan2 in the C standard libraries on various platforms. #1791.

    • Moved ps_sets features to ps_set.type, #1738.

    • revamped intrinsics related to file I/O, in particular to reading and writing from standard in, out, and error: #1789.

    • renamed quantors as quantor: #1810.

    • adjustments to the visibility of various features: #1786, #1745, #1823, #1824, #1841, #1851, #1911.

  • Cheers,

    --The Fuzion Team.

    last changed: 2024-06-28