Skip to main content
CenXiv.org
This website is in trial operation, support us!
We gratefully acknowledge support from all contributors.
Contribute
Donate
cenxiv logo > cs > arXiv:2510.07851

Help | Advanced Search

Computer Science > Programming Languages

arXiv:2510.07851 (cs)
[Submitted on 9 Oct 2025 ]

Title: The Functional Machine Calculus III: Control

Title: 函数机演算 III:控制

Authors:Willem Heijltjes
Abstract: The Functional Machine Calculus (Heijltjes 2022) is a new approach to unifying the imperative and functional programming paradigms. It extends the lambda-calculus, preserving the key features of confluent reduction and typed termination, to embed computational effects, evaluation strategies, and control flow operations. The first instalment modelled sequential higher-order computation with global store, input/output, probabilities, and non-determinism, and embedded both the call-by-name and call-by-value lambda-calculus, as well as Moggi's computational metalanguage and Levy's call-by-push-value. The present paper extends the calculus from sequential to branching and looping control flow. This allows the faithful embedding of a minimal but complete imperative language, including conditionals, exception handling, and iteration, as well as constants and algebraic data types. The calculus is defined through a simple operational semantics, extending the (simplified) Krivine machine for the lambda-calculus with multiple operand stacks to model effects and a continuation stack to model sequential, branching, and looping computation. It features a confluent reduction relation and a system of simple types that guarantees termination of the machine and strong normalization of reduction (in the absence of iteration). These properties carry over to the embedded imperative language, providing a unified functional-imperative model of computation that supports simple types, a direct and intuitive operational semantics, and a confluent reduction semantics.
Abstract: 函数机演算(Heijltjes 2022)是一种统一命令式和函数式编程范式的全新方法。 它扩展了λ演算,保留了可收敛归约和类型终止的关键特性,以嵌入计算效果、求值策略和控制流操作。 第一个版本模拟了带有全局存储、输入/输出、概率和非确定性的顺序高阶计算,并嵌入了按名调用和按值调用的λ演算,以及Moggi的计算元语言和Levy的按压值调用。 本文将演算从顺序扩展到分支和循环控制流。 这使得能够忠实嵌入一个最小但完整的命令式语言,包括条件语句、异常处理和迭代,以及常量和代数数据类型。 该演算通过一个简单的操作语义定义,扩展了λ演算的(简化)Krivine机器,加入多个操作栈来模拟效果,以及一个延续栈来模拟顺序、分支和循环计算。 它具有可收敛的归约关系和一个简单的类型系统,保证机器的终止和归约的强正规化(在没有迭代的情况下)。 这些特性也适用于嵌入的命令式语言,提供了一个支持简单类型、直接直观的操作语义和可收敛归约语义的统一的功能-命令式计算模型。
Subjects: Programming Languages (cs.PL) ; Logic in Computer Science (cs.LO)
Cite as: arXiv:2510.07851 [cs.PL]
  (or arXiv:2510.07851v1 [cs.PL] for this version)
  https://doi.org/10.48550/arXiv.2510.07851
arXiv-issued DOI via DataCite

Submission history

From: Willem Heijltjes [view email]
[v1] Thu, 9 Oct 2025 06:48:54 UTC (117 KB)
Full-text links:

Access Paper:

    View a PDF of the paper titled
  • View Chinese PDF
  • View PDF
  • TeX Source
license icon view license
Current browse context:
cs.LO
< prev   |   next >
new | recent | 2025-10
Change to browse by:
cs
cs.PL

References & Citations

  • NASA ADS
  • Google Scholar
  • Semantic Scholar
a export BibTeX citation Loading...

BibTeX formatted citation

×
Data provided by:

Bookmark

BibSonomy logo Reddit logo

Bibliographic and Citation Tools

Bibliographic Explorer (What is the Explorer?)
Connected Papers (What is Connected Papers?)
Litmaps (What is Litmaps?)
scite Smart Citations (What are Smart Citations?)

Code, Data and Media Associated with this Article

alphaXiv (What is alphaXiv?)
CatalyzeX Code Finder for Papers (What is CatalyzeX?)
DagsHub (What is DagsHub?)
Gotit.pub (What is GotitPub?)
Hugging Face (What is Huggingface?)
Papers with Code (What is Papers with Code?)
ScienceCast (What is ScienceCast?)

Demos

Replicate (What is Replicate?)
Hugging Face Spaces (What is Spaces?)
TXYZ.AI (What is TXYZ.AI?)

Recommenders and Search Tools

Influence Flower (What are Influence Flowers?)
CORE Recommender (What is CORE?)
IArxiv Recommender (What is IArxiv?)
  • Author
  • Venue
  • Institution
  • Topic

arXivLabs: experimental projects with community collaborators

arXivLabs is a framework that allows collaborators to develop and share new arXiv features directly on our website.

Both individuals and organizations that work with arXivLabs have embraced and accepted our values of openness, community, excellence, and user data privacy. arXiv is committed to these values and only works with partners that adhere to them.

Have an idea for a project that will add value for arXiv's community? Learn more about arXivLabs.

Which authors of this paper are endorsers? | Disable MathJax (What is MathJax?)
  • About
  • Help
  • contact arXivClick here to contact arXiv Contact
  • subscribe to arXiv mailingsClick here to subscribe Subscribe
  • Copyright
  • Privacy Policy
  • Web Accessibility Assistance
  • arXiv Operational Status
    Get status notifications via email or slack

京ICP备2025123034号