GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — laserpants - Overview

@laserpants laserpants Follow
More
  • Overview
  • Repositories
  • Projects
  • Packages
  • Stars
@laserpants
laserpants
Follow
View laserpants's full-sized avatar

Heikki Johannes Hildén laserpants

Follow
Eat the beans, wear the jeans.
140 followers · 35 following

Achievements

Achievement: QuickdrawAchievement: Pull Sharkx2Achievement: Arctic Code Vault ContributorAchievement: Starstruckx3

Achievements

Achievement: QuickdrawAchievement: Pull Sharkx2Achievement: Arctic Code Vault ContributorAchievement: Starstruckx3
More
  • Overview
  • Repositories
  • Projects
  • Packages
  • Stars
laserpants/README.md

🪇 My projects

Coal

Coal is a statically typed, purely functional programming language with Hindley–Milner type system, algebraic data types, extensible records, traits, and codata. The Coal compiler is implemented in Haskell.

As a total language, Coal takes a different approach to recursion, following the motto that "recursion is the goto of functional programming." To guarantee that programs are provably terminating, recursion is only available in a restricted form, known as structural recursion.

fun sum(numbers : List<int32>) : int32 =
  fold(numbers) {
    | [] => 0
    | x :: @tot => x + tot
  }

The language finds inspiration in ideas from the field of Mathematics of Program Construction, where streams and other infinite data types are described as coalgebras — hence the name Coal.

See the official website for a language manual and getting started instructions.

IR Builder

A Haskell library for constructing LLVM IR programmatically. It provides a monadic DSL for building modules, functions, blocks, and instructions, along with a pure renderer that serializes the result to LLVM assembly.

You describe an IR module using the IRBuilder monad. When you run compileModule, the builder produces an IRModule value. renderModule then converts that value to the textual LLVM IR format that can be passed to llc, clang, or lli. For example:

import LLVM.IR

example :: IRBuilder ()
example = do
  define i32 "add_one" [(i32, "x")] LExternal [] $ do
    beginBlock "entry"
    r <- add i32 (OLocal i32 "x") (OConstant (CInt 32 1))
    ret r

Running compileModule "example" example produces:

define i32 @add_one(i32 %x) {
entry:
  %1 = add i32 %x, 1
  ret i32 %1
}

Buy me a coffee

Pinned Loading

  1. coal coal Public

    Read-only mirror of https://codeberg.org/laserpants/coal

    Haskell

  2. ir-builder ir-builder Public

    Read-only mirror of https://codeberg.org/laserpants/ir-builder

    Haskell

  3. qt-material-widgets qt-material-widgets Public

    🎨 Qt widgets-based implementation of the Material Design specification.

    C++ 3.6k 747

  4. lambdapants lambdapants Public

    ✨ A REPL for the untyped Lambda Calculus. (Work in progress)

    Idris 3

Something went wrong, please refresh the page to try again.
If the problem persists, check the GitHub status page or contact support.

Uh oh!

There was an error while loading. Please reload this page.

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.