Skip to content
프로젝트

소개

https://codeberg.org/inko-lang/inko의 읽기 전용 미러

프로그래밍 언어 및 런타임

이 수치를 측정하는 방법

측정된 스타 증가

in 24h
0
in 7 days
+1
in 15 days
+2
in 1 month
+2

서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.

README.md

Original

Inko logo Inko

Inko is a language for building concurrent software with confidence. Inko makes it easy to build concurrent software, without having to worry about unpredictable performance, unexpected runtime errors, or race conditions.

Inko features deterministic automatic memory management, move semantics, static typing, type-safe concurrency, efficient error handling, and more. Inko source code is compiled to machine code using LLVM.

For more information, refer to the Inko website or the documentation. If you'd like to follow the development of Inko, consider joining our Discord server.

Examples

Hello world:

import std.stdio (Stdout)

type async Main {
  fn async main {
    Stdout.new.print('Hello, world!')
  }
}

A simple concurrent program:

import std.stdio (Stdout)
import std.sync (Promise)

type async Calculator {
  fn async fact(output: uni Promise[Int], size: Int) {
    let result = 1.to(size).iter.reduce(1, fn (product, val) { product * val })

    output.set(result)
  }
}

type async Main {
  fn async main {
    let calc = Calculator()

    # This calculates the factorial of 15 in the background and waits for the
    # result to be sent back to us:
    let val = await calc.fact(15)

    # Print a message along with the result to STDOUT:
    Stdout.new.print('the factorial of 15 is: ${val}')
  }
}

For more examples, refer to the website.

Installation

Details about how to install Inko and its requirements can be found in the "Installing Inko" guide in the Inko manual.

License

All source code in this repository is licensed under the Mozilla Public License version 2.0, unless stated otherwise. A copy of this license can be found in the file "LICENSE".

관련 프로젝트 살펴보기

불러오는 중…