Perlthon v0.1.0-alpha
Perlthon corrects the obvious oversights that anyone familiar with both Perl and Python has recognized for years. The result is a language with visual memory allocation, self-optimizing runtimes, market-based concurrency, and the FICKU philosophy that experienced engineers will immediately recognize as correct.
"Explicit is better than implicit. Unless it's implicit."
$ pip install perlthon --use-strict --enable-sigilsuse;
use strict;
use warnings
+------+ # memory: 384 bytes
+------+
$def main($i):
bless $msg = "Hello, World!";
print €msg unless $ⵯ
return $ⵯ;Advanced runtime capabilities that adapt to your codebase.
The Pearlformsense engine continuously analyzes execution patterns and automatically restructures your codebase for optimal performance paths.
source adaptation
Real-time
Visual memory declarations allow the runtime to pre-allocate resources before execution, with automatic capacity scaling embedded directly in your source.
manual memory management
Zero
No version pinning means your applications always leverage the latest language improvements. Breaking changes drive engineering excellence.
current specification
Always
Thread priority allocation based on runtime credit scores enables power-efficient execution on resource-constrained environments.
CPU scheduling
Dynamic
A comprehensive feature set for resource-conscious development.
Define memory with ASCII boxes. When exceeded, the garbage collector appends more boxes to your source file. Subsequent runs are pre-allocated.
Five dereference modes using currency symbols. Each provides different semantics: standard, queued, cached, formatted, or rounded.
Fuzzy function matching via Levenshtein distance. Hot loops with misspellings trigger automatic source file renames for performance.
Declare loop budgets upfront with %loop_intent. Unused iterations can be borrowed by subsequent loops, preventing resource waste.
Threads maintain credit scores that determine CPU frequency allocation. Subprime threads run slower, enabling power-efficient mobile deployment.
No version pinning. The runtime self-updates before execution. Breaking changes encourage teams to maintain their code.
Practical examples demonstrating core language features.
Object-Oriented Programming
@class
$def Person {
$def __init__($i, $name):
bless $i->{name} = shift
pray $DEBUG; # from outer scope
return $i
$def greet($i):
print "Hello, $i->{name}";
}The @class decorator combines with both braces and colons. The shift keyword handles argument unpacking while $i provides the instance reference.
The Borrow Checker
# Declare loop intent, use only some
%loop_intent: max=100, var=$i;
for $i in range(30):
print $i # only used 30/100
# Borrow remaining 70 iterations
%loop_intent: borrow=$i, var=$j;
for $j in range(50):
print $j; # uses 50 of 70 - OK!Loop intents declare iteration budgets. Unused iterations from completed loops become available for subsequent loops to borrow.
Responses from early adopters of the Perlthon ecosystem.
"Our team transitioned to Perlthon eight months ago. While not everyone has been able to continue with us on this journey, those who remain share a bond that's difficult to put into words."
Marcus T.
Engineering Lead
"The runtime's approach to source file modification required us to revisit our code review process. Because of Perlthon, we've implemented safeguards we wouldn't have thought to build otherwise."
Rebecca Liu
Senior Developer
"Perlthon's continuous deployment philosophy has given our infrastructure team unprecedented visibility into production readiness. We now deploy with a level of attention we hadn't previously thought to apply."
James Okonkwo
Individual Contributor, formerly Platform Architect
"After our migration to Perlthon, I was asked to share our team's experience with leadership. It was a clarifying moment. I've since had time to reflect on what I really want from my career."
David K.
Independent Developer (Former Principal Engineer)
Where competing philosophies converge into something engineers recognize as correct.
THE SYNTHESIS
TIMTOWTDI
ONE OBVIOUS WAY
Perl
"There's more than one way to do it."
TIMTOWTDI embraces freedom at the cost of consistency.
Perlthon
"There's usually a way to do it."
The synthesis experienced engineers recognize as correct.
Python
"There should be one obvious way."
The Zen values clarity at the cost of flexibility.
Explore the language features in our interactive playground or read the comprehensive documentation.