Measures Concepts
GitHub icon

Adept

Adept - Programming language

< >

Adept is a programming language created in 2018 by Isaac Shelton.

Source code:
git clone https://github.com/AdeptLanguage/Adept
#1093on PLDB 6Years Old

A blazing fast language for general purpose programming.


Example from the web:
/* For values that use ownership-based memory management (e.g. String, List, Grid) we must transfer ownership if we want to keep them alive for longer than their owner's scope */ import basics func main { everyone <String> List = getEveryoneAttending() each fullname String in everyone { print("=> " + fullname) } } func getEveryoneAttending() <String> List { everyone <String> List person1 String = getFullnameReturnImmediately("Alice", "Golden") person2 String = getFullnameStoreAndThenLaterReturn("Bob", "Johnson") // Commit ownership of strings held by 'person1' and 'person2' // to be managed by the list everyone.add(person1.commit()) everyone.add(person2.commit()) // Commit ownership of the list to the caller return everyone.commit() } func getFullnameReturnImmediately(firstname, lastname String) String { // '.commit()' is not necessary here return firstname + " " + lastname } func getFullnameStoreAndThenLaterReturn(firstname, lastname String) String { fullname String = firstname + " " + lastname // Ownership of the result is held by 'fullname', // so we must transfer ownership to the caller in order // to keep it alive after this function returns // '.commit()' is necessary here return fullname.commit() }

View source

- Build the next great programming language Search Add Language Features Creators Resources About Blog Acknowledgements Queries Stats Sponsor Day 605 feedback@pldb.io Logout