{"product_id":"build-your-own-programming-language-clinton-l-jeffery-9781804618028","title":"Build your own Programming Language - Second Edition: A developer's comprehensive guide to crafting, compiling, and implementing programming languages","description":"\u003cp\u003e\u003cstrong\u003eEmbark on a journey through essential components of language design, compiler construction, preprocessors, transpilers, and runtime systems in this second edition, authored by the creator of the Unicon programming language.\u003c\/strong\u003e\u003c\/p\u003e\u003cp\u003e\u003cstrong\u003ePurchase of the print or Kindle book includes a free PDF eBook\u003c\/strong\u003e\u003c\/p\u003eKey Features\u003cul\u003e\n\u003cli\u003eTakes a hands-on approach; learn by building the Jzero language, a subset of Java, with example code shown in both the Java and Unicon languages\u003c\/li\u003e\n\u003cli\u003eLearn how to create parsers, code generators, scanners, and interpreters\u003c\/li\u003e\n\u003cli\u003eTarget bytecode, native code, and preprocess or transpile code into a high-level language\u003c\/li\u003e\n\u003c\/ul\u003eBook Description\u003cp\u003eThere are many reasons to build a programming language: out of necessity, as a learning exercise, or just for fun. Whatever your reasons, this book gives you the tools to succeed.\u003c\/p\u003e\u003cp\u003eYou'll build the frontend of a compiler for your language and generate a lexical analyzer and parser using Lex and YACC tools. Then you'll explore a series of syntax tree traversals before looking at code generation for a bytecode virtual machine or native code. In this edition, a new chapter has been added to assist you in comprehending the nuances and distinctions between preprocessors and transpilers. Code examples have been modernized, expanded, and rigorously tested, and all content has undergone thorough refreshing. You'll learn to implement code generation techniques using practical examples, including the Unicon Preprocessor and transpiling Jzero code to Unicon. You'll move to domain-specific language features and learn to create them as built-in operators and functions. You'll also cover garbage collection.\u003c\/p\u003e\u003cp\u003eDr. Jeffery's experiences building the Unicon language are used to add context to the concepts, and relevant examples are provided in both Unicon and Java so that you can follow along in your language of choice.\u003c\/p\u003e\u003cp\u003eBy the end of this book, you'll be able to build and deploy your own domain-specific language.\u003c\/p\u003eWhat you will learn\u003cul\u003e\n\u003cli\u003eAnalyze requirements for your language and design syntax and semantics.\u003c\/li\u003e\n\u003cli\u003eWrite grammar rules for common expressions and control structures.\u003c\/li\u003e\n\u003cli\u003eBuild a scanner to read source code and generate a parser to check syntax.\u003c\/li\u003e\n\u003cli\u003eImplement syntax-coloring for your code in IDEs like VS Code.\u003c\/li\u003e\n\u003cli\u003eWrite tree traversals and insert information into the syntax tree.\u003c\/li\u003e\n\u003cli\u003eImplement a bytecode interpreter and run bytecode from your compiler.\u003c\/li\u003e\n\u003cli\u003eWrite native code and run it after assembling and linking using system tools.\u003c\/li\u003e\n\u003cli\u003ePreprocess and transpile code into another high-level language\u003c\/li\u003e\n\u003c\/ul\u003eWho this book is for\u003cp\u003eThis book is for software developers interested in the idea of inventing their own language or developing a domain-specific language. Computer science students taking compiler design or construction courses will also find this book highly useful as a practical guide to language implementation to supplement more theoretical textbooks. Intermediate or better proficiency in Java or C++ programming languages (or another high-level programming language) is assumed.\u003c\/p\u003eTable of Contents\u003col\u003e\n\u003cli\u003eWhy Build Another Programming Language?\u003c\/li\u003e\n\u003cli\u003eProgramming Language Design\u003c\/li\u003e\n\u003cli\u003eScanning Source Code\u003c\/li\u003e\n\u003cli\u003eParsing\u003c\/li\u003e\n\u003cli\u003eSyntax Trees\u003c\/li\u003e\n\u003cli\u003eSymbol Tables\u003c\/li\u003e\n\u003cli\u003eChecking Base Types\u003c\/li\u003e\n\u003cli\u003eChecking Types on Arrays, Method Calls, and Structure Accesses\u003c\/li\u003e\n\u003cli\u003eIntermediate Code Generation\u003c\/li\u003e\n\u003cli\u003eSyntax Coloring in an IDE\u003c\/li\u003e\n\u003cli\u003ePreprocessors and Transpilers\u003c\/li\u003e\n\u003cli\u003eBytecode Interpreters\u003c\/li\u003e\n\u003cli\u003eGenerating Bytecode\u003c\/li\u003e\n\u003cli\u003eNative Code Generation\u003c\/li\u003e\n\u003cli\u003eImplementing Operators and Built-In Functions\u003c\/li\u003e\n\u003cli\u003eDomain Control Structures\u003c\/li\u003e\n\u003cli\u003eGarbage Collection\u003c\/li\u003e\n\u003cli\u003eFinal Thoughts\u003c\/li\u003e\n\u003cli\u003eAppendix: Unicon Essentials\u003c\/li\u003e\n\u003cli\u003eAnswers\u003c\/li\u003e\n\u003c\/ol\u003e\u003cbr\u003e\u003cbr\u003e\u003cb\u003eAuthor:\u003c\/b\u003e Clinton L. Jeffery, Imran Ahmad\u003cbr\u003e\u003cb\u003eISBN-10:\u003c\/b\u003e 1804618020\u003cbr\u003e\u003cb\u003eISBN-13:\u003c\/b\u003e 9781804618028\u003cbr\u003e\u003cb\u003ePublisher:\u003c\/b\u003e Packt Publishing\u003cbr\u003e\u003cb\u003eLanguage:\u003c\/b\u003e English\u003cbr\u003e\u003cb\u003ePublished:\u003c\/b\u003e 01\/30\/2024\u003cbr\u003e\u003cb\u003ePages:\u003c\/b\u003e 556\u003cbr\u003e\u003cb\u003eFormat:\u003c\/b\u003e Paperback\u003cbr\u003e\u003cb\u003eWeight:\u003c\/b\u003e 2.08lbs\u003cbr\u003e\u003cb\u003eSize:\u003c\/b\u003e 9.25h x 7.50w x 1.13d","brand":"Clinton L. Jeffery","offers":[{"title":"Paperback","offer_id":44809595650303,"sku":"9781804618028","price":49.99,"currency_code":"USD","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0662\/2982\/9887\/files\/img_4702fffa-b40a-4332-bcfd-b46fabff2e26.jpg?v=1707926936","url":"https:\/\/www.whiterainbookhouse.com\/products\/build-your-own-programming-language-clinton-l-jeffery-9781804618028","provider":"WR Book House","version":"1.0","type":"link"}