Merge branch 'develop' into pyext

pull/335/head
A. R. Shajii 2023-02-05 22:40:48 -05:00
commit 5920148d8d
3 changed files with 5 additions and 4 deletions

View File

@ -1,10 +1,10 @@
cmake_minimum_required(VERSION 3.14)
project(
Codon
VERSION "0.15.4"
VERSION "0.15.5"
HOMEPAGE_URL "https://github.com/exaloop/codon"
DESCRIPTION "high-performance, extensible Python compiler")
set(CODON_JIT_PYTHON_VERSION "0.1.2")
set(CODON_JIT_PYTHON_VERSION "0.1.3")
configure_file("${PROJECT_SOURCE_DIR}/cmake/config.h.in"
"${PROJECT_SOURCE_DIR}/codon/config/config.h")
configure_file("${PROJECT_SOURCE_DIR}/cmake/config.py.in"

View File

@ -284,7 +284,7 @@ void SimplifyVisitor::visit(FunctionStmt *stmt) {
// If there are captures, replace `fn` with `fn(cap1=cap1, cap2=cap2, ...)`
if (!captures.empty()) {
finalExpr = N<CallExpr>(N<IdExpr>(stmt->name), partialArgs);
// Add updated self reference if case function is recursive!
// Add updated self reference in case function is recursive!
auto pa = partialArgs;
for (auto &a : pa) {
if (!a.name.empty())

View File

@ -171,7 +171,8 @@ void TranslateVisitor::visit(IdExpr *expr) {
auto val = ctx->find(expr->value);
seqassert(val, "cannot find '{}'", expr->value);
if (expr->value == "__vtable_size__")
result = make<ir::IntConst>(expr, ctx->cache->classRealizationCnt + 2, getType(expr->getType()));
result = make<ir::IntConst>(expr, ctx->cache->classRealizationCnt + 2,
getType(expr->getType()));
else if (auto *v = val->getVar())
result = make<ir::VarValue>(expr, v);
else if (auto *f = val->getFunc())