{"id":22823,"date":"2024-01-10T23:06:49","date_gmt":"2024-01-11T05:06:49","guid":{"rendered":"https:\/\/blinkingrobots.com\/the-design-principles-of-the-elixir-type-system\/"},"modified":"2024-01-10T23:06:49","modified_gmt":"2024-01-11T05:06:49","slug":"the-design-principles-of-the-elixir-type-system","status":"publish","type":"post","link":"https:\/\/blinkingrobots.com\/the-design-principles-of-the-elixir-type-system\/","title":{"rendered":"The Design Rules of the Elixir Sort System"},"content":{"rendered":"\n2024-01-10 16:44:25 <\/p>\n
Giuseppe Castagna The Artwork, Science, and Engineering of Programming, 2024, Vol. 8, Subject 2, Article 4<\/p>\n Submission date: 2023-05-31 Elixir is a dynamically-typed purposeful language working on the Erlang Digital Machine, designed for constructing scalable and maintainable functions. Its traits have earned it a surging adoption by a whole lot of business actors and tens of 1000’s of builders. Static typing appears these days to be crucial request coming from the Elixir group. We current a gradual kind system we plan to incorporate within the Elixir compiler, define its traits and design rules, and present by some brief examples learn how to use it in apply.<\/p>\n Creating a static kind system appropriate for Erlang\u2019s household of languages has been an open analysis downside for nearly 20 years. Our system transposes to this household of languages a polymorphic kind system with set-theoretic sorts and semantic subtyping. To do this, we had to enhance and lengthen each semantic subtyping and the typing methods thereof, to account for a number of traits of those languages\u2014and of Elixir specifically\u2014such because the arity of capabilities, the usage of guards, a uniform remedy of data and dictionaries, the necessity for a brand new sound gradual typing self-discipline that doesn’t depend on the insertion at compile time of particular run-time type-tests however, slightly, takes under consideration each the sort checks carried out by the digital machine and people explicitly added by the programmer.<\/p>\n The system offered right here is \u201cprogressively\u201d being carried out and built-in in Elixir, however a prototype implementation is already accessible.<\/p>\n The purpose of this work is to function a longstanding reference that might be used to introduce sorts to Elixir programmers, in addition to to trace at some future instructions and potential evolutions of the Elixir language.<\/p>\n<\/p><\/div>\n<\/a>, Guillaume Duboc
<\/a>, and Jos\u00e9 Valim
<\/a><\/p>\n
Publication date: 2023-10-15
DOI: https:\/\/doi.org\/10.22152\/programming-journal.org\/2024\/8\/4<\/a>
Full textual content: PDF<\/a><\/p>\nSummary<\/h3>\n