Skip to content

Releases: vitreo12/omni

0.4.2

29 Mar 13:32
Compare
Choose a tag to compare

Abort if nim != 1.6.0.

0.4.1

28 May 14:51
Compare
Choose a tag to compare

Check CHANGELOG.md

0.4.0

12 May 23:02
Compare
Choose a tag to compare

Check CHANGELOG.md

0.2.3

28 Oct 18:13
Compare
Choose a tag to compare
  • Fix for -d:lto on MacOS
  • Added -v flag and copyright
  • Added Error printing on Warning[GcMem]

0.2.2

21 Oct 09:16
Compare
Choose a tag to compare
  • Support for Nim 1.4.0
  • Added -d:lto flag
  • Added --panics:on flag
  • Delay length defaults to 1

0.2.1

03 Oct 10:28
Compare
Choose a tag to compare

0.2.1

  1. Introducing the loop construct:

    loop 4 i:
        print i
  2. Better error printing for invalid def and struct builds.

0.2.0

30 Sep 10:23
Compare
Choose a tag to compare

0.2.0

  1. Support for command-like calls. Just like nim, it works for one arguments only:

    a = Data 10
    a = Data(10) #equivalent
  2. Support for new statement, both as dotExpr and command:

    a = new Data
    a = new Data 10
    a = new Data(10)
    a = Data.new()
    a = Data.new(10)
  3. Explicit casting at variables declaration will keep the type:

    a = int(1) #Will be int, not float!
  4. Variables and Buffers can now be declared from the ins statement:

    ins 2:
        buffer Buffer
        speed  {1, 0, 10}
    
    outs 1
    
    init:
        phase = 0.0
    
    sample:
        scaled_rate = buffer.samplerate / samplerate
        out1 = buffer[phase]
        phase += (speed * scaled_rate)
        phase = phase % buffer.len
  5. Added tuples support:

    def giveMeATuple():
        a (int, int) = (1, 2) #OR a = (int(1), int(2))
        b = (1, 2, a) #(float, float, (int, int))
        return b     
    
    init:
        a = giveMeATuple()
        print a[0]; print a[1]
        print a[2][0]; print a[2][1]
  6. Introducing modules via the use / require statements (they are equivalent, still deciding which name I like better):

    One.omni:

    struct Something:
        a
    
    def someFunc():
        return 0.7

    Two.omni

    struct Something:
        a
    
    def someFunc():
        return 0.3

    Three.omni:

    use One:
        Something as Something1
        someFunc as someFunc1
    
    use Two:
        Something as Something2
        someFunc as someFunc2
    
    init:
        one = Something1()
        two = Something2()
    
    sample:
        out1 = someFunc1() + someFunc2()

    For more complex examples, check the NewModules folder in omni_lang's tests.

  7. Better handling of variables' scope. if / elif / else / for / while have their own scope, but won't overwrite variables of encapsulating scopes.

    init:
        a = 0
        if in1 > 0:
            a = 2 #Gonna change declared a
            b = 0 #b belongs to this if statement
        else:
            a = 3 #Gonna change declared a
            b = 1 #b belongs to this else statement

0.1.0

21 Aug 10:35
Compare
Choose a tag to compare
0.1.0 Pre-release
Pre-release

First alpha release!