{"id":366,"date":"2011-07-04T23:43:01","date_gmt":"2011-07-04T15:43:01","guid":{"rendered":"http:\/\/gergely.imreh.net\/blog\/?p=366"},"modified":"2011-07-04T23:43:01","modified_gmt":"2011-07-04T15:43:01","slug":"language-of-the-month-lua-part-2","status":"publish","type":"post","link":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/","title":{"rendered":"Language of the Month: Lua, part 2"},"content":{"rendered":"<p>I&#8217;m a few days behind schedule since Lua was June&#8217;s language, but here it comes, some summary of my experience, after setting things up in the <a title=\"Language of the Month: Lua\" href=\"http:\/\/gergely.imreh.net\/blog\/2011\/06\/language-of-the-month-lua\/\" target=\"_blank\">first part<\/a>.<\/p>\n<figure id=\"attachment_392\" aria-describedby=\"caption-attachment-392\" style=\"width: 300px\" class=\"wp-caption aligncenter\"><a href=\"http:\/\/gergely.imreh.net\/blog\/wp-content\/uploads\/2011\/07\/vlcsnap-151508.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-medium wp-image-392 \" title=\"Moon\" src=\"http:\/\/gergely.imreh.net\/blog\/wp-content\/uploads\/2011\/07\/vlcsnap-151508-300x225.png\" alt=\"A Trip to the Moon \/ Le Voyage dans la Lune\" width=\"300\" height=\"225\" \/><\/a><figcaption id=\"caption-attachment-392\" class=\"wp-caption-text\">Lua is not this painful, indeed, just the opposite<\/figcaption><\/figure>\n<h2>Overview<\/h2>\n<p>I really liked this language, and I&#8217;m sure I&#8217;ll keep learning it. Very useful and lots of interesting concepts. I haven&#8217;t seen an embedded language before, and some parts<\/p>\n<p>Most of what I picked up was from <a title=\"Beginning Lua Programming book's site\" href=\"http:\/\/www.wrox.com\/WileyCDA\/WroxTitle\/Beginning-Lua-Programming.productCd-0470069171.html\" target=\"_blank\">Beginning Lua Programming<\/a> and\u00a0<a title=\"Programming in Lua, First Edition\" href=\"http:\/\/www.lua.org\/pil\/index.html\" target=\"_blank\">Programming in Lua<\/a>.\u00a0<a title=\"Lua Missjons on Github\" href=\"https:\/\/github.com\/kikito\/lua_missions\" target=\"_blank\">Lua Missions<\/a> was another very useful experience: a &#8220;fill in the blank&#8221; type of source code collection, which drilled my understanding of the Lua concepts. Some sections felt a little short, so maybe later I&#8217;ll think whether there are any more questions I can come up with. Very well worth the time!<\/p>\n<p>There are two things that stand out: tables and local environments.<\/p>\n<h3>Tables<\/h3>\n<p>If I have to refer to my knowledge of Python, then Lua tables are like Python lists and dicts rolled into one and then some. Here&#8217;s one such table:<\/p>\n<pre lang=\"lua\">x = {1, 2, 3, y = \"something\", [\"or else\"]=\"what\"}<\/pre>\n<p>The first three elements are giving an array (and one can loop over them), then the last two are key-value pairs. One tricky thing is that the &#8220;y&#8221; there is actually a string (the same as [&#8220;y&#8221;]), just made it more readable with syntactic sugar. Since variables (references to variables) can be keys as well, this can get confusing if one has a variable called &#8220;y&#8221;&#8230; There are quite a few things about tables that are confusing, but actually pretty consistent so my fuses are not blowing that much as they were in the beginning (for example: how the length is looked up, how to iterate through the different values) .<\/p>\n<p>They are very complex animals so some things are quite complex to do, which in turn enables quite complex things to be done. Pretty much any kind of data structure can be built upon them. So all in all, I&#8217;m enjoying them with all their quirks. Also, &#8220;weak tables&#8221; are an interesting concept (where certain table entries can garbage collected).<\/p>\n<h3>Scopes<\/h3>\n<p>In Python, the name spaces and environments seem to be on the sidelines (at least what I&#8217;ve seen so far): people need it and have to us it, but nothing more than that. In Lua this is taken to a whole new level: scopes can be essential parts of the way algorithms are implemented and neat tricks can be played.<\/p>\n<p>I tried to come up with some good example and failed, here&#8217;s a &#8220;duh&#8221; one:<\/p>\n<pre lang=\"lua\">function newCounter ()\r\n    local i = 0\r\n    return function ()   -- anonymous function\r\n        i = i + 1\r\n        return i\r\n    end\r\nend\r\n\r\nc1 = newCounter()\r\nprint(c1())  -- 1\r\nprint(c1())  -- 2<\/pre>\n<p>This is a bit like Python&#8217;s &#8220;<a title=\"yield explained on StackOverflow\" href=\"http:\/\/stackoverflow.com\/questions\/231767\/the-python-yield-keyword-explained\/231855#231855\" target=\"_blank\">yield<\/a>&#8221; type of generator, without anything special.<\/p>\n<p>Also, in Python there are only two kinds of variables (I think): local and global: either just for you or for everyone. Here they have one more: upvalues, where the variable is local to a parent, so children environment can access them but the parent&#8217;s parents cannot. They are strange beasts as well, e.g. the code itself cannot really know if a variable is upvalue or global, only that it can access that.<\/p>\n<p>And of course these scopes help embedding to not just be possible but straightforward and powerful. Local environments can be restricted, some things selectively enabled, and all this transparently, so the script running might not even know that it&#8217;s being in the Matrix.<\/p>\n<h2>The Lua Experience<\/h2>\n<h3>Good<\/h3>\n<ul>\n<li>Fast, both start up and running<\/li>\n<li>Language itself is quite small, possible to wrap one&#8217;s head around quite easily<\/li>\n<li>Written in ANSI C, so basically on every architecture where one can run C, one can have Lua as well<\/li>\n<li>Quite a few program has Lua interpreter or interface built in, see the <a title=\"List of Lua-enabled applications\" href=\"http:\/\/en.wikipedia.org\/wiki\/Lua_(programming_language)#Applications\" target=\"_blank\">list of these at Wikipedia<\/a><\/li>\n<li>Tables are great and once one mastered them, are really Swiss Army Knives<\/li>\n<li>Built in interpreter (though could use a little love like <a title=\"iPython homepage\" href=\"http:\/\/ipython.scipy.org\/moin\/\" target=\"_blank\">iPython<\/a>)<\/li>\n<li>The &#8220;&#8230;&#8221; syntax for variable number of arguments<\/li>\n<li>Astrological naming convention &#8211; modules are <em>rocks<\/em>,\u00a0the\u00a0exercises\u00a0I linked previously are missions, web framework is <a title=\"Kepler: the Lua Web Framework homepage\" href=\"http:\/\/www.keplerproject.org\/\" target=\"_blank\">Kepler<\/a>&#8230;<\/li>\n<\/ul>\n<h3>Bad<\/h3>\n<ul>\n<li>There seem to be a lot of reserved names (e.g. in\u00a0<a title=\"Metatables section Programming in Lua\" href=\"http:\/\/www.lua.org\/pil\/index.html#13\" target=\"_blank\">metatables<\/a>) that would be pretty much impossible to figure out with a book (and\/or an iPython-like helpful environment), though this is a problem probably only when starting out with Lua<\/li>\n<\/ul>\n<h3>Ugly<\/h3>\n<ul>\n<li>While some complex things can be solved, some simple things can require complex coding (e.g. in case of the tables when using &#8220;<a title=\"__index in Programming in Lua\" href=\"http:\/\/www.lua.org\/pil\/13.4.1.html\" target=\"_blank\">__index<\/a>&#8221; and &#8220;<a title=\"__newindex in Programming in Lua\" href=\"http:\/\/www.lua.org\/pil\/13.4.2.html\" target=\"_blank\">__newindex<\/a>&#8220;) and there are things that are not even possible. Or I just misunderstood some sections of the book.<\/li>\n<li>Using a lot of syntactic sugar (especially in the <a title=\"Object Oriented programming of Lua\" href=\"http:\/\/www.lua.org\/pil\/index.html#16\" target=\"_blank\">object oriented section<\/a>), that I feel need some more practice to pick up, as things can be done in multiple ways<\/li>\n<li>The tables&#8217; syntactic sugar covered way of handling string keys, convenient when things go well, mighty confusing at even the slightest problem<\/li>\n<li>Too few projects using Lua, too few sources of information (this is not the language&#8217;s fault, though)<\/li>\n<\/ul>\n<h2>Project<\/h2>\n<p>Originally I wanted to do some useful programming in every language I learn during the Language of the Month series. I failed with Scala (lazy), and now failed with Lua too (underestimating the difficulty). I&#8217;m using VLC a lot and it has Lua scripting enabled, so I wanted to do a plugin that can be useful for me later as well. This didn&#8217;t work out very well, mainly because it feels the VLC Lua interface is not very well documented, one mostly have to find some examples that exist already and use them. I ended up wasting a lot of time and still don&#8217;t quite understand how to do certain things I would like for my code, and don&#8217;t even know if it&#8217;s possible to do or not. Will come back to it later, until that here are a few links that helped me to get started:<\/p>\n<ul>\n<li><a title=\"Instructions to code your own VLC Lua scripts.\" href=\"http:\/\/www.videolan.org\/developers\/vlc\/share\/lua\/README.txt\" target=\"_blank\">VLC Lua FAQ<\/a> &#8211; detailed list of available API functions, but almost no context and examples<\/li>\n<li><a title=\"Lua script souces\" href=\"http:\/\/git.videolan.org\/gitweb.cgi?p=vlc.git;a=tree;f=share\/lua;h=1bd0a9fe2ddcf6a07b8910bbb25dc7f66c832b5c;hb=HEAD\" target=\"_blank\">Lua extensions in the VLC git repo<\/a> &#8211; one can pick up something by checking out those examples<\/li>\n<li><a title=\"Extending VLC with Lua\" href=\"http:\/\/www.coderholic.com\/extending-vlc-with-lua\/\" target=\"_blank\">Example: Streaming Radio Player Extension<\/a> &#8211; someone who have gone further down this road than me and has a working extension. Very educational, especially to see how concise and straightforward it can be, because the VLC Lua API seems to be thought out well.<\/li>\n<\/ul>\n<p>Again, hopefully pick this up later (I mean it).<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;m a few days behind schedule since Lua was June&#8217;s language, but here it comes, some summary of my experience, after setting things up in the first part. Overview I really liked this language, and I&#8217;m sure I&#8217;ll keep learning it. Very useful and lots of interesting concepts. I haven&#8217;t seen an embedded language before, [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[44,49],"class_list":["post-366","post","type-post","status-publish","format-standard","hentry","category-prog","tag-lotm","tag-lua"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Language of the Month: Lua, part 2 - ClickedyClick<\/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:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/\" \/>\n<meta property=\"og:locale\" content=\"en_GB\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Language of the Month: Lua, part 2 - ClickedyClick\" \/>\n<meta property=\"og:description\" content=\"I&#8217;m a few days behind schedule since Lua was June&#8217;s language, but here it comes, some summary of my experience, after setting things up in the first part. Overview I really liked this language, and I&#8217;m sure I&#8217;ll keep learning it. Very useful and lots of interesting concepts. I haven&#8217;t seen an embedded language before, [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/\" \/>\n<meta property=\"og:site_name\" content=\"ClickedyClick\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/gergely.imreh\" \/>\n<meta property=\"article:author\" content=\"https:\/\/www.facebook.com\/gergely.imreh\" \/>\n<meta property=\"article:published_time\" content=\"2011-07-04T15:43:01+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/gergely.imreh.net\/blog\/wp-content\/uploads\/2011\/07\/vlcsnap-151508-300x225.png\" \/>\n<meta name=\"author\" content=\"Gergely Imreh\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@imrehg\" \/>\n<meta name=\"twitter:site\" content=\"@imrehg\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Gergely Imreh\" \/>\n\t<meta name=\"twitter:label2\" content=\"Estimated reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/\"},\"author\":{\"name\":\"Gergely Imreh\",\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/#\\\/schema\\\/person\\\/42391e2ae52c8ed76b37be509a5707b0\"},\"headline\":\"Language of the Month: Lua, part 2\",\"datePublished\":\"2011-07-04T15:43:01+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/\"},\"wordCount\":1088,\"commentCount\":4,\"publisher\":{\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/#\\\/schema\\\/person\\\/42391e2ae52c8ed76b37be509a5707b0\"},\"image\":{\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/#primaryimage\"},\"thumbnailUrl\":\"http:\\\/\\\/gergely.imreh.net\\\/blog\\\/wp-content\\\/uploads\\\/2011\\\/07\\\/vlcsnap-151508-300x225.png\",\"keywords\":[\"lotm\",\"lua\"],\"articleSection\":[\"Programming\"],\"inLanguage\":\"en-GB\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/\",\"url\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/\",\"name\":\"Language of the Month: Lua, part 2 - ClickedyClick\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/#primaryimage\"},\"thumbnailUrl\":\"http:\\\/\\\/gergely.imreh.net\\\/blog\\\/wp-content\\\/uploads\\\/2011\\\/07\\\/vlcsnap-151508-300x225.png\",\"datePublished\":\"2011-07-04T15:43:01+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/#breadcrumb\"},\"inLanguage\":\"en-GB\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/#primaryimage\",\"url\":\"http:\\\/\\\/gergely.imreh.net\\\/blog\\\/wp-content\\\/uploads\\\/2011\\\/07\\\/vlcsnap-151508-300x225.png\",\"contentUrl\":\"http:\\\/\\\/gergely.imreh.net\\\/blog\\\/wp-content\\\/uploads\\\/2011\\\/07\\\/vlcsnap-151508-300x225.png\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/2011\\\/07\\\/language-of-the-month-lua-part-2\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Language of the Month: Lua, part 2\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/\",\"name\":\"ClickedyClick\",\"description\":\"Life in real, complex and digital.\",\"publisher\":{\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/#\\\/schema\\\/person\\\/42391e2ae52c8ed76b37be509a5707b0\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-GB\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/#\\\/schema\\\/person\\\/42391e2ae52c8ed76b37be509a5707b0\",\"name\":\"Gergely Imreh\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1d5be311c5d616a3f4c7dfbc6b736ec817d2508b8c420ec29edb950d33fb4946?s=96&d=retro&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1d5be311c5d616a3f4c7dfbc6b736ec817d2508b8c420ec29edb950d33fb4946?s=96&d=retro&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1d5be311c5d616a3f4c7dfbc6b736ec817d2508b8c420ec29edb950d33fb4946?s=96&d=retro&r=g\",\"caption\":\"Gergely Imreh\"},\"logo\":{\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1d5be311c5d616a3f4c7dfbc6b736ec817d2508b8c420ec29edb950d33fb4946?s=96&d=retro&r=g\"},\"description\":\"Physicist, hacker. Enjoys avant-guarde literature probably a bit too much. Open source advocate and contributor, both for software and hardware. Follow these posts on the Fediverse by @gergely@gergely.imreh.net\",\"sameAs\":[\"https:\\\/\\\/gergely.imreh.net\\\/\",\"https:\\\/\\\/www.facebook.com\\\/gergely.imreh\",\"https:\\\/\\\/www.instagram.com\\\/imrehg\\\/\",\"https:\\\/\\\/www.linkedin.com\\\/in\\\/gergelyimreh\\\/\",\"https:\\\/\\\/www.youtube.com\\\/@GergelyImreh\"],\"url\":\"https:\\\/\\\/gergely.imreh.net\\\/blog\\\/author\\\/gergely\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Language of the Month: Lua, part 2 - ClickedyClick","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:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/","og_locale":"en_GB","og_type":"article","og_title":"Language of the Month: Lua, part 2 - ClickedyClick","og_description":"I&#8217;m a few days behind schedule since Lua was June&#8217;s language, but here it comes, some summary of my experience, after setting things up in the first part. Overview I really liked this language, and I&#8217;m sure I&#8217;ll keep learning it. Very useful and lots of interesting concepts. I haven&#8217;t seen an embedded language before, [&hellip;]","og_url":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/","og_site_name":"ClickedyClick","article_publisher":"https:\/\/www.facebook.com\/gergely.imreh","article_author":"https:\/\/www.facebook.com\/gergely.imreh","article_published_time":"2011-07-04T15:43:01+00:00","og_image":[{"url":"http:\/\/gergely.imreh.net\/blog\/wp-content\/uploads\/2011\/07\/vlcsnap-151508-300x225.png","type":"","width":"","height":""}],"author":"Gergely Imreh","twitter_card":"summary_large_image","twitter_creator":"@imrehg","twitter_site":"@imrehg","twitter_misc":{"Written by":"Gergely Imreh","Estimated reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/#article","isPartOf":{"@id":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/"},"author":{"name":"Gergely Imreh","@id":"https:\/\/gergely.imreh.net\/blog\/#\/schema\/person\/42391e2ae52c8ed76b37be509a5707b0"},"headline":"Language of the Month: Lua, part 2","datePublished":"2011-07-04T15:43:01+00:00","mainEntityOfPage":{"@id":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/"},"wordCount":1088,"commentCount":4,"publisher":{"@id":"https:\/\/gergely.imreh.net\/blog\/#\/schema\/person\/42391e2ae52c8ed76b37be509a5707b0"},"image":{"@id":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/#primaryimage"},"thumbnailUrl":"http:\/\/gergely.imreh.net\/blog\/wp-content\/uploads\/2011\/07\/vlcsnap-151508-300x225.png","keywords":["lotm","lua"],"articleSection":["Programming"],"inLanguage":"en-GB","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/","url":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/","name":"Language of the Month: Lua, part 2 - ClickedyClick","isPartOf":{"@id":"https:\/\/gergely.imreh.net\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/#primaryimage"},"image":{"@id":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/#primaryimage"},"thumbnailUrl":"http:\/\/gergely.imreh.net\/blog\/wp-content\/uploads\/2011\/07\/vlcsnap-151508-300x225.png","datePublished":"2011-07-04T15:43:01+00:00","breadcrumb":{"@id":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/#breadcrumb"},"inLanguage":"en-GB","potentialAction":[{"@type":"ReadAction","target":["https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/"]}]},{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/#primaryimage","url":"http:\/\/gergely.imreh.net\/blog\/wp-content\/uploads\/2011\/07\/vlcsnap-151508-300x225.png","contentUrl":"http:\/\/gergely.imreh.net\/blog\/wp-content\/uploads\/2011\/07\/vlcsnap-151508-300x225.png"},{"@type":"BreadcrumbList","@id":"https:\/\/gergely.imreh.net\/blog\/2011\/07\/language-of-the-month-lua-part-2\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/gergely.imreh.net\/blog\/"},{"@type":"ListItem","position":2,"name":"Language of the Month: Lua, part 2"}]},{"@type":"WebSite","@id":"https:\/\/gergely.imreh.net\/blog\/#website","url":"https:\/\/gergely.imreh.net\/blog\/","name":"ClickedyClick","description":"Life in real, complex and digital.","publisher":{"@id":"https:\/\/gergely.imreh.net\/blog\/#\/schema\/person\/42391e2ae52c8ed76b37be509a5707b0"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/gergely.imreh.net\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-GB"},{"@type":["Person","Organization"],"@id":"https:\/\/gergely.imreh.net\/blog\/#\/schema\/person\/42391e2ae52c8ed76b37be509a5707b0","name":"Gergely Imreh","image":{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/secure.gravatar.com\/avatar\/1d5be311c5d616a3f4c7dfbc6b736ec817d2508b8c420ec29edb950d33fb4946?s=96&d=retro&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/1d5be311c5d616a3f4c7dfbc6b736ec817d2508b8c420ec29edb950d33fb4946?s=96&d=retro&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/1d5be311c5d616a3f4c7dfbc6b736ec817d2508b8c420ec29edb950d33fb4946?s=96&d=retro&r=g","caption":"Gergely Imreh"},"logo":{"@id":"https:\/\/secure.gravatar.com\/avatar\/1d5be311c5d616a3f4c7dfbc6b736ec817d2508b8c420ec29edb950d33fb4946?s=96&d=retro&r=g"},"description":"Physicist, hacker. Enjoys avant-guarde literature probably a bit too much. Open source advocate and contributor, both for software and hardware. Follow these posts on the Fediverse by @gergely@gergely.imreh.net","sameAs":["https:\/\/gergely.imreh.net\/","https:\/\/www.facebook.com\/gergely.imreh","https:\/\/www.instagram.com\/imrehg\/","https:\/\/www.linkedin.com\/in\/gergelyimreh\/","https:\/\/www.youtube.com\/@GergelyImreh"],"url":"https:\/\/gergely.imreh.net\/blog\/author\/gergely\/"}]}},"_links":{"self":[{"href":"https:\/\/gergely.imreh.net\/blog\/wp-json\/wp\/v2\/posts\/366","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/gergely.imreh.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/gergely.imreh.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/gergely.imreh.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/gergely.imreh.net\/blog\/wp-json\/wp\/v2\/comments?post=366"}],"version-history":[{"count":14,"href":"https:\/\/gergely.imreh.net\/blog\/wp-json\/wp\/v2\/posts\/366\/revisions"}],"predecessor-version":[{"id":395,"href":"https:\/\/gergely.imreh.net\/blog\/wp-json\/wp\/v2\/posts\/366\/revisions\/395"}],"wp:attachment":[{"href":"https:\/\/gergely.imreh.net\/blog\/wp-json\/wp\/v2\/media?parent=366"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/gergely.imreh.net\/blog\/wp-json\/wp\/v2\/categories?post=366"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/gergely.imreh.net\/blog\/wp-json\/wp\/v2\/tags?post=366"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}