Skip to Content
Polished Ruby Programming
book

Polished Ruby Programming

by Jeremy Evans
July 2021
Intermediate to advanced
434 pages
8h 36m
English
Packt Publishing
Content preview from Polished Ruby Programming

Chapter 10: Designing Useful Domain-Specific Languages

Ruby makes it easy to implement domain-specific languages (DSLs), and many popular libraries offer DSLs to improve their usability.

In this chapter, you'll learn how to design and implement a DSL, which problems are handled well by DSLs, and both the advantages and disadvantages of using DSLs in your libraries.

We will cover the following topics:

  • Designing your DSL
  • Implementing your DSL
  • Learning when to use a DSL

By the end of the chapter, you'll have a better understanding of not only how to design a DSL, but why it may or may not be a good idea to do so.

Technical requirements

In this chapter and all chapters of this book, code given in code blocks is designed to be executed on Ruby ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Programming Ruby 3.3

Programming Ruby 3.3

Noel Rappin, Dave Thomas
The Ruby Programming Language

The Ruby Programming Language

David Flanagan, Yukihiro Matsumoto

Publisher Resources

ISBN: 9781801072724Supplemental Content