
{"id":1978,"date":"2026-07-03T10:00:00","date_gmt":"2026-07-03T08:00:00","guid":{"rendered":"https:\/\/www.pcjv.de\/?p=1978"},"modified":"2026-07-24T17:24:31","modified_gmt":"2026-07-24T15:24:31","slug":"go-dws-a-pascal-thread-continued-in-go","status":"publish","type":"post","link":"https:\/\/www.pcjv.de\/?p=1978","title":{"rendered":"go-dws: a Pascal thread, continued in Go"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Of all my current projects, <a href=\"https:\/\/github.com\/CWBudde\/go-dws\" target=\"_blank\" rel=\"noopener\">go-dws<\/a> is the most personal: a reimplementation of DWScript \u2014 the object-oriented Object Pascal scripting engine \u2014 in Go. It is the continuation of a Pascal thread I have followed for decades, by other means.<\/p>\n\n\n\n<!--more-->\n\n\n\n<h2 class=\"wp-block-heading\">Why DWScript, again?<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">DWScript has accompanied me for a long time: I contributed to the <a href=\"https:\/\/github.com\/CWBudde\/DWScript\" target=\"_blank\" rel=\"noopener\">original Delphi project<\/a>, built the DWScriptExpert IDE plugin, wrote import tooling for Delphi units, and even used its JavaScript backend to ship web apps in Pascal (the Web-Apps post told that story). The language is small, expressive and pleasant \u2014 and reimplementing a language you love is the deepest way to understand it.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">When I picked up working on DWScript again, I was only able to do this with the help of LLMs. So this is also kind of an experiment about how good modern LLM tools have gotten. The first steps are always easy, but at some point it&#8217;s getting thick. So the first models all stuck at some point only bloating the project further and further. Only with the latest frontier models it&#8217;s finally possible to fix all the edge cases still left.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">The ecosystem around it<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">A language is only as useful as its tooling, so go-dws grew a family: a language server (<a href=\"https:\/\/github.com\/CWBudde\/go-dws-lsp\" target=\"_blank\" rel=\"noopener\">go-dws-lsp<\/a>), a VS Code extension (<a href=\"https:\/\/github.com\/CWBudde\/go-dws-vscode\" target=\"_blank\" rel=\"noopener\">go-dws-vscode<\/a>), a <a href=\"https:\/\/github.com\/CWBudde\/tree-sitter-dws\" target=\"_blank\" rel=\"noopener\">tree-sitter grammar<\/a>, and <a href=\"https:\/\/github.com\/CWBudde\/go-dws-primer\" target=\"_blank\" rel=\"noopener\">go-dws-primer<\/a> \u2014 an interactive teaching environment in the tradition of my old PascalPrimer, because a language you cannot teach with is only half a language.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Pascal as a habit of mind<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">People sometimes ask why I keep coming back to Pascal-shaped things while writing Go all day. The honest answer: the two languages share a temperament \u2014 explicit, readable, compiled, a little stubborn. Porting DWScript to Go is not nostalgia; it is carrying twenty-five years of language history into a runtime with goroutines, a real module system and single-binary deployment.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The project is work in progress and openly so \u2014 which, as the open source retrospective explained, is how I have always preferred to learn.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Of all my current projects, go-dws is the most personal: a reimplementation of DWScript \u2014 the object-oriented Object Pascal scripting engine \u2014 in Go. It is the continuation of a Pascal thread I have followed for decades, by other means.<\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[24,41],"tags":[],"class_list":["post-1978","post","type-post","status-publish","format-standard","hentry","category-delphi","category-go"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>go-dws: a Pascal thread, continued in Go - Christian&#039;s private site<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.pcjv.de\/?p=1978\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Christian\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.pcjv.de\\\/?p=1978#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.pcjv.de\\\/?p=1978\"},\"author\":{\"name\":\"Christian\",\"@id\":\"https:\\\/\\\/www.pcjv.de\\\/#\\\/schema\\\/person\\\/79b654f8c2fb5bf9405ccc4cb1c11880\"},\"headline\":\"go-dws: a Pascal thread, continued in Go\",\"datePublished\":\"2026-07-03T08:00:00+00:00\",\"dateModified\":\"2026-07-24T15:24:31+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.pcjv.de\\\/?p=1978\"},\"wordCount\":339,\"articleSection\":[\"Delphi\",\"Go\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.pcjv.de\\\/?p=1978\",\"url\":\"https:\\\/\\\/www.pcjv.de\\\/?p=1978\",\"name\":\"go-dws: a Pascal thread, continued in Go - Christian&#039;s private site\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.pcjv.de\\\/#website\"},\"datePublished\":\"2026-07-03T08:00:00+00:00\",\"dateModified\":\"2026-07-24T15:24:31+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/www.pcjv.de\\\/#\\\/schema\\\/person\\\/79b654f8c2fb5bf9405ccc4cb1c11880\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.pcjv.de\\\/?p=1978#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.pcjv.de\\\/?p=1978\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.pcjv.de\\\/?p=1978#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.pcjv.de\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"go-dws: a Pascal thread, continued in Go\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.pcjv.de\\\/#website\",\"url\":\"https:\\\/\\\/www.pcjv.de\\\/\",\"name\":\"Christian&#039;s private site\",\"description\":\"Private site of Christian-W. Budde\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.pcjv.de\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.pcjv.de\\\/#\\\/schema\\\/person\\\/79b654f8c2fb5bf9405ccc4cb1c11880\",\"name\":\"Christian\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/009d545df1a458e74ec172fa5dc19428c1144c2ee8f1ec82d94c3b28f12a0c14?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/009d545df1a458e74ec172fa5dc19428c1144c2ee8f1ec82d94c3b28f12a0c14?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/009d545df1a458e74ec172fa5dc19428c1144c2ee8f1ec82d94c3b28f12a0c14?s=96&d=mm&r=g\",\"caption\":\"Christian\"},\"sameAs\":[\"http:\\\/\\\/www.savioursofsoul.de\\\/Christian\"],\"url\":\"https:\\\/\\\/www.pcjv.de\\\/?author=3\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"go-dws: a Pascal thread, continued in Go - Christian&#039;s private site","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.pcjv.de\/?p=1978","twitter_misc":{"Written by":"Christian","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.pcjv.de\/?p=1978#article","isPartOf":{"@id":"https:\/\/www.pcjv.de\/?p=1978"},"author":{"name":"Christian","@id":"https:\/\/www.pcjv.de\/#\/schema\/person\/79b654f8c2fb5bf9405ccc4cb1c11880"},"headline":"go-dws: a Pascal thread, continued in Go","datePublished":"2026-07-03T08:00:00+00:00","dateModified":"2026-07-24T15:24:31+00:00","mainEntityOfPage":{"@id":"https:\/\/www.pcjv.de\/?p=1978"},"wordCount":339,"articleSection":["Delphi","Go"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.pcjv.de\/?p=1978","url":"https:\/\/www.pcjv.de\/?p=1978","name":"go-dws: a Pascal thread, continued in Go - Christian&#039;s private site","isPartOf":{"@id":"https:\/\/www.pcjv.de\/#website"},"datePublished":"2026-07-03T08:00:00+00:00","dateModified":"2026-07-24T15:24:31+00:00","author":{"@id":"https:\/\/www.pcjv.de\/#\/schema\/person\/79b654f8c2fb5bf9405ccc4cb1c11880"},"breadcrumb":{"@id":"https:\/\/www.pcjv.de\/?p=1978#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.pcjv.de\/?p=1978"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.pcjv.de\/?p=1978#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.pcjv.de\/"},{"@type":"ListItem","position":2,"name":"go-dws: a Pascal thread, continued in Go"}]},{"@type":"WebSite","@id":"https:\/\/www.pcjv.de\/#website","url":"https:\/\/www.pcjv.de\/","name":"Christian&#039;s private site","description":"Private site of Christian-W. Budde","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.pcjv.de\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.pcjv.de\/#\/schema\/person\/79b654f8c2fb5bf9405ccc4cb1c11880","name":"Christian","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/009d545df1a458e74ec172fa5dc19428c1144c2ee8f1ec82d94c3b28f12a0c14?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/009d545df1a458e74ec172fa5dc19428c1144c2ee8f1ec82d94c3b28f12a0c14?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/009d545df1a458e74ec172fa5dc19428c1144c2ee8f1ec82d94c3b28f12a0c14?s=96&d=mm&r=g","caption":"Christian"},"sameAs":["http:\/\/www.savioursofsoul.de\/Christian"],"url":"https:\/\/www.pcjv.de\/?author=3"}]}},"_links":{"self":[{"href":"https:\/\/www.pcjv.de\/index.php?rest_route=\/wp\/v2\/posts\/1978","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.pcjv.de\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.pcjv.de\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.pcjv.de\/index.php?rest_route=\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/www.pcjv.de\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1978"}],"version-history":[{"count":1,"href":"https:\/\/www.pcjv.de\/index.php?rest_route=\/wp\/v2\/posts\/1978\/revisions"}],"predecessor-version":[{"id":2106,"href":"https:\/\/www.pcjv.de\/index.php?rest_route=\/wp\/v2\/posts\/1978\/revisions\/2106"}],"wp:attachment":[{"href":"https:\/\/www.pcjv.de\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1978"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.pcjv.de\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1978"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.pcjv.de\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1978"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}