Languages update

Looking forward to updated language/library/runtime on next contest!

Any progress on this?

Will you add Scratch? It would allow my daughter to participate too :wink:

1 Like

There was some progress made. Should happen during August.

1 Like

I doubt that Scratch will be implemented any time soon. The Editor requires lots of changes, since it would be graphical instead of plain code. Theoretically it could be transpiled to JavaScript or Python. But what kind of code do you submit then? And how about submit size :wink:

Algobox is easier to implement here than a pure graphical Scratch (you can write scripts for Algobox).

The following languages have been updated:

  • Bash: GNU Bash 4.4.12 => GNU Bash 4.4.23
  • C: gcc 7.2.0 mode C11 => gcc 8.2.0 mode C17
  • C++: g++ 7.2.0 mode C++14 => g++ 8.2.0 mode C++17
  • C#: C# 6.0 (Mono 5.4.0, .NET 4.6) => C# 6.0 (Mono 5.12.0, .NET 4.6)
  • Clojure: 1.8.0 - Oracle JVM 1.8 => 1.9.0 - Oracle JVM 1.8
  • Dart: 1.24.2 => 1.24.3
  • F#: no update
  • Java: no update (waiting for Java 11)
  • Javascript: SpiderMonkey 58.0 (ES6) => SpiderMonkey 63.0 (ES6)
  • Go: 1.9.1 => 1.10.3
  • Groovy: 2.4.12 - Oracle JVM 1.8 => 2.5.1 - Oracle JVM 1.8
  • Haskell: GHC 8.2.1 => Haskell Platform 8.4.3
  • Kotlin: no update (no answer from the Kotlin team)
  • Lua: 5.3.4 => 5.3.5
  • Objective C: Clang 3.4 -> Clang 4.0
  • OCaml: 4.05.0 => 4.07.0
  • Pascal: Free Pascal Compiler 3.0.2 => Free Pascal Compiler 3.0.4
  • Perl: no update
  • PHP: 7.1.9 => 7.2.8
  • Python 2: 2.7.14 => 2.7.15
  • Python 3: 3.6.3 => 3.6.6
  • Ruby: 2.4.2 => 2.5.1
  • Rust: 1.21.0 => 1.27.2
  • Scala: 2.12.4 => 2.12.6
  • Swift: 4.0.3 => 4.1.3
  • VB.NET: Compiler Visual Basic 2005 (Mono 5.4.0, .NET 4.5) => Compiler Visual Basic 2005 (Mono 5.12.0, .NET 4.6)

@qbit86 about C# 7, the Mono support is only partial support

7 Likes

about C# 7, the Mono support is only partial support

@TwoSteps Why Mono, and not .NET Core 2.1 for Linux? Does this version of Mono support ArrayPool<T>, Span<T>, Memory<T> from both runtime/library and language perspective? (Cannot try by myself at the moment.)

Why jumping straight from 8 to 11, rather than incremental updates ?

Edit: OK, I guess LTS…

Wondering if Mono can handle features like these:

using System;
using System.Buffers;

internal static class Program
{
    private static void Main()
    {
        int dynamicLength = DateTime.Now.Second;
        Span<double> span = stackalloc double[dynamicLength];
        bool[] array = ArrayPool<bool>.Shared.Rent(dynamicLength);
        using (IMemoryOwner<int> owner = MemoryPool<int>.Shared.Rent(dynamicLength)) { }
        ReadOnlySpan<char> slice = "{ i: 1729 }".AsSpan().Slice(5, 4);
        bool valid = int.TryParse(slice, out int result);
        Console.WriteLine($"{nameof(result)}: {result}");
    }
}

Hello Thibaud,
Have you ever considered adding the Cython module?
Could be useful for bot contest…

2 Likes

@TwoSteps Unfortunately, Mono cannot compile this code :(

error CS0122: `System.Span<T>' is inaccessible due to its protection level
error CS0122: `System.Buffers.ArrayPool<T>' is inaccessible due to its protection level

Could you please add latest .NET Core as an alternative to Mono?

1 Like

about C# 7, the Mono support is only partial support

Link mentions that following C# 7 features are supported:

  • Default literal expressions
  • Readonly struct

But using them in IDE renders errors:

  • “error CS1644: Feature `default literal’ cannot be used because it is not part of the C# 7.0 language specification”
  • “error CS1644: Feature `readonly structs’ cannot be used because it is not part of the C# 7.0 language specification”

Is there some switch in your build script that fixes version to be 7.0 and not the latest supported (7.2 or 7.3)?

@Jahz for Java, we thought Java 9 and 10 didn’t bring much so we prefer to wait for 11

@qbit86 Mono was there first :grin: . We should check if .Net Core supports Vb.Net too because we don’t want to keep both Mono and .Net Core

We support C# 6.0, not 7.0 or later

@JLT I’ll ask the devs about Cython

3 Likes

We support C# 6.0, not 7.0 or later

It would be great if you specified 7.2 langversion switch in build script, even if it is only partially supported in Mono.

They say it’s possible to build VB app for .NET Core with Visual Studio; so it’s likely supported via command line too.
https://docs.microsoft.com/en-us/dotnet/core/tutorials/vb-with-visual-studio

Please, add switch -langversion:latest or at least -langversion:7.2 when running Mono’s csc (actually Roslyn). It is only 7.0 by default on Mono 5.12.0, but 7.2 is supported:

$ "/c/Program Files/Mono/bin/csc" /langversion:?
Supported language versions:
default
1
2
3
4
5
6
7.0 (default)
7.1
7.2 (latest)
latest

@TwoSteps Please!

1 Like

Not sure if this is related to the recent language update but the tensorflow puzzle appears broken: ImportError: No module named six (https://www.codingame.com/ide/puzzle/deep-learning-tensorflow). This error appears without having the import in the IDE code.

My code for this challenge was working and this issue was pointed out on the chat by someone trying the puzzle (@Patricia). Could you check it out please :slight_smile: ?

1 Like

Thank you, great work with keeping the languages up to date :slight_smile:

Can you please elaborate on this? Is close collaboration required to update a language version, or do you need approval to use it by the developers? I mean 1.1.50 is OK but I expected an update this time around :slight_smile:

I’d like to second the request for .Net Core (2.1 preferred) for C#, F# and VB.Net please. This will make it support all the same features for all Windows/Linux/Mac, has many new and useful language features and is the most performant version of the .Net ecosystem to date.

Thanks :grinning:

3 Likes