skip to main content
10.1145/3340671.3343358acmotherconferencesArticle/Chapter ViewAbstractPublication PagesecoopConference Proceedingsconference-collections
research-article

Implementing Babylonian/S by Putting Examples Into Contexts: Tracing Instrumentation for Example-based Live Programming as a Use Case for Context-oriented Programming

Published: 15 July 2019 Publication History

Abstract

Based on context-oriented programming (COP), we implemented source code instrumentation for example-based live programming in a modular way. These tools provide programmers with feedback on the dynamic program behavior by showing traced values of example invocations of a program. For that, we have to trace intermediate, expression-level runtime states during the execution of an example. As the instrumentation is only intended to improve tool support, the default behavior of the system must not be altered. In this paper, we demonstrate how context-oriented programming can be used to keep the execution of examples separate from the default behavior even in the presence of expression-level behavior variations. We illustrate our approach by implementing Babylonian Programming using ContextS2 in Squeak/Smalltalk. Based on the implementation, we compare our COP-based Smalltalk implementation to the module-rewriting-based implementation for JavaScript.

References

[1]
Jonathan Edwards. 2004. Example Centric Programming. In Companion to the 19th Annual ACM SIGPLAN Conference on Object-oriented Programming Systems, Languages, and Applications (OOPSLA) 2004. ACM, New York, NY, USA, 124--124.
[2]
Robert Hirschfeld, Pascal Costanza, and Oscar Nierstrasz. 2008. Context-Oriented Programming. The Journal of Object Technology 7, 3 (2008), 125--125.
[3]
Daniel Ingalls, Ted Kaehler, John Maloney, Scott Wallace, and Alan Kay. 1997. Back to the Future: The Story of Squeak, a Practical Smalltalk Written in Itself. In Proceedings of OOPSLA 1997, Vol. 32. ACM, 318--326.
[4]
Martin Löwis, Marcus Denker, and Oscar Nierstrasz. 2007. Context-Oriented Programming: Beyond Layers. Proceedings of the 2007 international conference on Dynamic languages in conjunction with the 15th International Smalltalk Joint Conference (ICDL 2007) (2007), 143--156.
[5]
Sean McDirmid. 2013. Usable Live Programming. In Proceedings of the ACM International Symposium on New Ideas, New Paradigms, and Reflections on Programming & Software (Onward!) 2013. ACM, New York, NY, USA, 53--62.
[6]
Gerard Meszaros. 2007. xUnit test patterns: Refactoring test code. Pearson Education.
[7]
David Rauch, Patrick Rein, Stefan Ramson, Jens Lincke, and Robert Hirschfeld. 2019. Babylonian-Style Programming: Design and Implementation of an Integration of Live Examples Into General-Purpose Source Code. The Art, Science, and Engineering of Programming 3, 3 (2019).
[8]
Patrick Rein, Stefan Ramson, Jens Lincke, Robert Hirschfeld, and Tobias Pape. 2018. Exploratory and Live, Programming and Coding: A Literature Study Comparing Perspectives on Liveness. The Art, Science, and Engineering of Programming 3, 1 (2018).
[9]
Marcel Taeumel, Tim Felgentreff, and Robert Hirschfeld. 2014. Applying Data-Driven Tool Development to Context-Oriented Languages. Proceedings of 6th International Workshop on Context-Oriented Programming (COP 2014) (2014).
[10]
Alessandro Warth, Patrick Dubroy, and Tony Garnock-Jones. 2016. Modular Semantic Actions. Proceedings of the 12th Symposium on Dynamic Languages - DLS 2016 (2016).

Cited By

View all
  • (2024)Implementing Babylonian/G by Putting Examples into Game ContextsCompanion Proceedings of the 8th International Conference on the Art, Science, and Engineering of Programming10.1145/3660829.3660847(68-72)Online publication date: 11-Mar-2024
  • (2024)Assessing Live Programming for Program ComprehensionProceedings of the 2024 on Innovation and Technology in Computer Science Education V. 110.1145/3649217.3653547(520-526)Online publication date: 3-Jul-2024
  • (2023)Toward Studying Example-Based Live Programming in CS/SE EducationProceedings of the 2nd ACM SIGPLAN International Workshop on Programming Abstractions and Interactive Notations, Tools, and Environments10.1145/3623504.3623568(17-24)Online publication date: 18-Oct-2023
  • Show More Cited By

Index Terms

  1. Implementing Babylonian/S by Putting Examples Into Contexts: Tracing Instrumentation for Example-based Live Programming as a Use Case for Context-oriented Programming

      Recommendations

      Comments

      Information & Contributors

      Information

      Published In

      cover image ACM Other conferences
      COP '19: Proceedings of the 11th ACM International Workshop on Context-Oriented Programming
      July 2019
      37 pages
      ISBN:9781450368636
      DOI:10.1145/3340671
      Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

      In-Cooperation

      Publisher

      Association for Computing Machinery

      New York, NY, United States

      Publication History

      Published: 15 July 2019

      Permissions

      Request permissions for this article.

      Check for updates

      Author Tags

      1. Squeak/Smalltalk
      2. context-oriented programming
      3. example-based live programming
      4. use case

      Qualifiers

      • Research-article
      • Research
      • Refereed limited

      Conference

      ECOOP '19

      Acceptance Rates

      Overall Acceptance Rate 17 of 25 submissions, 68%

      Contributors

      Other Metrics

      Bibliometrics & Citations

      Bibliometrics

      Article Metrics

      • Downloads (Last 12 months)6
      • Downloads (Last 6 weeks)0
      Reflects downloads up to 14 Feb 2025

      Other Metrics

      Citations

      Cited By

      View all
      • (2024)Implementing Babylonian/G by Putting Examples into Game ContextsCompanion Proceedings of the 8th International Conference on the Art, Science, and Engineering of Programming10.1145/3660829.3660847(68-72)Online publication date: 11-Mar-2024
      • (2024)Assessing Live Programming for Program ComprehensionProceedings of the 2024 on Innovation and Technology in Computer Science Education V. 110.1145/3649217.3653547(520-526)Online publication date: 3-Jul-2024
      • (2023)Toward Studying Example-Based Live Programming in CS/SE EducationProceedings of the 2nd ACM SIGPLAN International Workshop on Programming Abstractions and Interactive Notations, Tools, and Environments10.1145/3623504.3623568(17-24)Online publication date: 18-Oct-2023
      • (2023)Probe Log: Visualizing the Control Flow of Babylonian ProgrammingCompanion Proceedings of the 7th International Conference on the Art, Science, and Engineering of Programming10.1145/3594671.3594679(61-67)Online publication date: 13-Mar-2023
      • (2022)Example MiningCompanion Proceedings of the 6th International Conference on the Art, Science, and Engineering of Programming10.1145/3532512.3535226(60-66)Online publication date: 21-Mar-2022
      • (2021)Toward Patterns of Exploratory Programming PracticeDesign Thinking Research10.1007/978-3-030-76324-4_7(127-150)Online publication date: 12-Aug-2021
      • (2020)Example-based live programming for everyone: building language-agnostic tools for live programming with LSP and GraalVMProceedings of the 2020 ACM SIGPLAN International Symposium on New Ideas, New Paradigms, and Reflections on Programming and Software10.1145/3426428.3426919(1-17)Online publication date: 18-Nov-2020
      • (2020)Zone-based Layer ActivationProceedings of the 12th ACM International Workshop on Context-Oriented Programming and Advanced Modularity10.1145/3422584.3422764(1-10)Online publication date: 21-Jul-2020
      • (2020)Focused Live Programming with Loop SeedsProceedings of the 33rd Annual ACM Symposium on User Interface Software and Technology10.1145/3379337.3415834(607-613)Online publication date: 20-Oct-2020
      • (2020)Projection Boxes: On-the-fly Reconfigurable Visualization for Live ProgrammingProceedings of the 2020 CHI Conference on Human Factors in Computing Systems10.1145/3313831.3376494(1-7)Online publication date: 21-Apr-2020

      View Options

      Login options

      View options

      PDF

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader

      Figures

      Tables

      Media

      Share

      Share

      Share this Publication link

      Share on social media