Skip to content

Creator of Lua: Scripting, Programming Languages, Predictions | Roberto Ierusalimschy

The Peterman Pod

Hosted by Ryan Peterman

1h 5m
Transcript

Original podcast

Where to listen

Summary

Written by a model from the transcript; not yet reviewed.

Roberto Ierusalimschy, the creator of the Lua programming language, joins the show to discuss programming language design, the philosophy behind Lua, and his thoughts on the future of software development. They examine why Lua was designed specifically as a library to be embedded in C rather than as a standalone language, how its minimalistic nature and lack of built-in bloat make it exceptionally fast and portable, and why script-based embedding offers powerful security sandboxing benefits. The conversation also covers the trade-offs of zero versus one-based indexing, the perils of committee-driven feature creep, and how artificial intelligence might change the future of coding and programming languages.

  • Lua is architected as a library from the ground up, making it uniquely suited to be embedded into C or C++ applications. 4:10
  • Using a minimalist scripting language like Lua inside a larger C or Python application acts as a secure sandbox, preventing arbitrary code execution. 34:15
  • Programming language features should be scrutinized carefully because committee-driven design often leads to unnecessary complexity and feature creep. 37:25
  • Lua uses one-based indexing because real-world systems like books, chapters, and mathematics naturally start at one rather than zero. 45:26

Chapters

  1. 0:00
    Podcast Intro and Host Greeting

    The episode opens with the host introducing the guest and setting the stage for a discussion about Lua and programming language design.

  2. 4:05
    Embedding vs. Extending Lua

    The conversation delves into the two primary ways Lua interacts with host languages and why Lua excels at both embedding and extending.

  3. 4:49
    Designing Lua as a Library

    Roberto discusses the unique design decision of treating Lua as a library from the outset and its implications for embedding.

  4. 10:16
    Lua vs. Python: Performance and Features

    A comparison of Lua and Python highlights Lua’s minimalism, performance advantages, and differences in library ecosystems.

  5. 11:52
    Scripting Language vs. Dynamic Language

    The hosts clarify the distinction between scripting languages and dynamic languages, using Lua and JavaScript as examples.

  6. 32:48
    Lua’s State Management and Sandboxing

    Roberto explains how Lua’s state isolation provides sandboxing benefits for security and controlled execution.

  7. 40:08
    Historical Design Choices: Booleans and Indexing

    The discussion covers early Lua decisions such as omitting booleans and adopting one-based indexing, and their rationale.

  8. 51:43
    Future of Programming with AI

    Roberto reflects on how AI might influence the need for traditional programming languages and the importance of simplicity and clarity.

  9. 1:00:10
    Advice for Aspiring Programmers

    The episode concludes with recommendations on which languages to learn and how to approach language design and complexity.

  10. 1:03:30
    Roberto’s Early Career

    Roberto discusses his beginnings in programming and early influences.

  11. 1:04:12
    Closing Remarks and Call to Action

    Hosts thank Roberto, encourage support, and promote a Kickstarter project.

Highlights

  • 1:07

    Dual Language Architectureinsight

    The guest explains that Lua is designed as a scripting language where C or C++ handles the resource-intensive core and main loop, while Lua handles dynamic, frequently changing tasks.

  • 4:10

    Language As A Libraryinsight

    Unlike Python or other standalone languages, Lua was written from inception as a library whose command-line interface is just a client of that official library API.

  • 10:29

    Performance Focusdata

    The guest discusses how Lua achieves performance by avoiding many features that cannot be implemented efficiently, and because its virtual machine easily fits inside CPU cache.

  • 36:07

    Hardware Safety Sandboxingstory

    The guest shares an example where Lua is used as a sandbox to prevent untrusted inputs from directly controlling critical hardware ports or core program invariants.

  • 37:25

    Committee Design Pitfallsinsight

    The guest argues that languages designed by committees suffer because everyone fights to add their favorite features while few advocate against adding complexity.

  • 45:26

    Defending One-Based Indexingdebate

    The guest defends Lua's one-based indexing by pointing out that real-world entities like book chapters and mathematical sequences start at one, and zero-indexing arose largely from C's pointer arithmetic.

  • 51:43

    AI And Programming Languagesinsight

    The guest speculates that if AI advances to write all code directly, programming languages might become obsolete, though simplicity remains crucial for human verification.

Quotes

  • “Lua is a language that usually you use together, combined with another language like C or C++.”
    Unnamed speaker · 1:07
  • “I think Haskell, I think is a, is incredible language. It has everything you need to really learn about functional programming.”
    Unnamed speaker · 1:00:27
  • “To know a lot of stuff, you really have to study a lot of stuff.”
    Unnamed speaker · 1:03:34
  • “People say, oh, learn Lua in thirty minutes or learn Python in five minutes.”
    Unnamed speaker · 1:03:42
  • ergonomic keyboard 1:04:42–1:05:11

About this episode

Roberto Ierusalimschy is the creator of the Lua programming language. I interviewed him about Lua's unique strengths, programming language design and predictions for how AI will impact programming languages. • My ergonomic keyboard project I mentioned, you can follow along here: https://read.compose.llc/ • The Kickstarter page for it: https://www.kickstarter.com/projects/ryanlpeterman/compose-simple-ergonomics-beautifully-done Podcast links: • YouTube: https://youtu.be/jCZnFKk6M9A • Apple: https://podcasts.apple.com/us/podcast/the-peterman-pod/id1777363835 • Transcript: https://www.developing.dev/p/creator-of-lua-scripting-programming Thank you to this episode's sponsor for supporting my work: • WorkOS: makes your app Enterprise Ready with easy to use APIs to add SSO, SCIM, RBAC, and more in just a few lines of code, check them out at https://workos.com/ Timestamps: (00:00) Intro (00:43) What sets Lua apart (08:35) Comparing Lua with Python (13:04) Top book recommendation on language design (14:20) How JIT works and why it is hard (23:21) Compiling Python and interpreting C (30:31) How cross language calls work (36:58) Lua unique design decisions (51:17) Predictions for AIs impact on languages (01:00:10) Top 3 languages to learn to become a better engineer (01:03:21) Advice for his younger self (01:04:19) Outro Where to find Roberto: • Website: https://www.inf.puc-rio.br/~roberto/ • Wikipedia: https://en.wikipedia.org/wiki/Roberto_Ierusalimschy Where to find Ryan: • Newsletter: https://www.developing.dev/ • X/Twitter: https://x.com/ryanlpeterman • LinkedIn: https://www.linkedin.com/in/ryanlpeterman/ • Threads: https://www.threads.com/@ryanlpeterman • Instagram: https://www.instagram.com/ryanlpeterman • TikTok: https://www.tiktok.com/@ryanlpeterman Referenced in this episode: • The Evolution of Lua: https://www.lua.org/doc/hopl.pdf • LuaJIT: https://luajit.org/ • How much does it cost: https://www.youtube.com/watch?v=EUvgoxBm7uc • JavaScript: The Good Parts (not an affiliate link): https://www.amazon.com/dp/0596517742

Transcript

0:00
1:05:16

9,322 words · 2 speakers

Speaker names marked are inferred from speaking time and the show’s known hosts — they are not voice-verified.

Topics

  • Lua
  • Python
  • JavaScript
  • Lua JIT
  • World of Warcraft
  • Roblox

Page updated · transcript and summary are machine-generated