From b25ff71bb198c227b3202ee32a8067cda413bc16 Mon Sep 17 00:00:00 2001 From: Xavier Del Campo Romero Date: Sat, 9 May 2026 02:56:07 +0200 Subject: Add project skeleton --- README.md | 70 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 README.md (limited to 'README.md') diff --git a/README.md b/README.md new file mode 100644 index 0000000..a884dfa --- /dev/null +++ b/README.md @@ -0,0 +1,70 @@ +# `prc`, a compiler for the Prose programming language + +> **IMPORTANT NOTE**: Prose is still under heavy development. It is therefore +> not ready for production yet. + +Prose is a new and small programming language that aims for readability +and native interoperability with C. Its syntax, while a bit distant from +ALGOL-like languages like C, should still be readable to most programmers. + +Most remarkably, Prose avoids sigils such as `{}`, `$` or any other kind of +symbol, in favour of simple and readable English-like statements. +The only exception is `*`, which is used for comments: + +A hello world example: + +``` +* this is a comment +public function main +linkage + status word +procedure returning status + display "hello world" + set status to 0 +``` + +As opposed to other programming languages such as Python, Prose follows +free-form syntax, and therefore the same program can be written in any format: + +``` +public function main linkage status word procedure returning status display "hello world" set status to 0 +``` + +Prose follows the C ABI and also inherits its type system: + +``` +public function main +imports "cstd" +linkage + status cint + argc cint + argv pointer to array of etc byte +storage + fd cint +procedure using argc argv returning status + display "argc=" argc ", argv=" argv + call socket using AF_INET SOCK_STREAM 0 returning fd + display "fd=" fd + call close using fd + set status to 0 +``` + +## LICENSE + +``` + prc, a compiler for the Prose programming language. + Copyright (C) 2026 Xavier Del Campo Romero + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Affero General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU Affero General Public License for more details. + + You should have received a copy of the GNU Affero General Public License + along with this program. If not, see . +``` -- cgit v1.2.3