Mozilla Closures and first-class functions I wrote a long and probably dull chapter on closures and first-class and higher-order functions in Rust. It goes into some detail on the implementation and some of the subtleties like higher-ranked lifetime
Mozilla Libmacro As I outlined in an earlier post, libmacro is a new crate designed to be used by procedural macro authors. It provides the basic API for procedural macros to interact with the compiler.
Mozilla A type-safe and zero-allocation library for reading and navigating ELF files Over the Christmas break I made a start implementing an ELF library in Rust. This was interesting for me since I've not done a lot of library work before. I hope it will
Mozilla Abstract return types, aka `impl Trait` There has been an idea around for a long time that we should allow functions to specify bounds on their return types, rather than give a concrete type. This has many benefits -
Mozilla My thoughts on Rust in 2016 2015 was a huge year for Rust - we released version 1.0, we stabilised huge swathes of the language and libraries, we grew massively as a community, and we re-organised the governance
Mozilla Procedural macros, framework In this blog post I'll lay out what I think procedural macros should look like. I've discussed the syntax elsewhere, and I'll discuss the API we make available to procedural macros in a
Mozilla Macro plans - syntax I would like to improve the syntax for both macros by example and procedural macros. For macros by example, there is a soft backwards compatibility constraint: although new macros do not have to
Mozilla Sets of scopes macro hygiene On the first day, God created programming languages, and he saw that they were good. On the second day, he saw that there were expressivity problems and he created macros. On the third
Mozilla Macro hygiene in all its guises and variations Note, I'm not sure of the terminology for some of this stuff, so I might be making horrible mistakes, apologies. Usually, when we talk about macro hygiene we mean the ability to not
Mozilla Macro plans, overview In this post I want to give a bit of an overview of the changes I'm planning to propose for the macro system. I haven't worked out some of the details yet, so
Mozilla Macros pt6 - more issues I discovered another couple of issues with Rust macros (both affect the macro_rules flavour). Nested macros and arguments These don't work because of the way macros do substitution. When expanding a macro,
Mozilla concat_idents! and macros in ident position In the next few blog posts I want to cover some areas for improvement for Rust macros. I'll drill down into one topic at a time. I'll propose solutions, but not in RFC-levels
Mozilla Macros in Rust pt5 I've previously laid out the current state of affairs in Rust (0, 1, 2, 3, 4). In this post I want to highlight what I think are issues with the current system and
Macros in Rust pt4 Previously: intro, macro_rules, procedural macros, hygiene. This post is a grab-bag of stuff that didn't fit elsewhere. First, I'll discuss some more macro_rules stuff around import/export/modularisation of macros. Then
Mozilla Macros in Rust pt3 Previously I covered macro_rules and procedural macros. In this post I'll cover macro hygiene in a bit more detail. In upcoming posts, I'll cover modularisation for macros, some implementation details, some areas
Macros in Rust pt2 (Continuing from last time). procedural macros Also known as syntax extensions or syntax plugins or compiler plugins (which they are just a category of). I'll not get into the naming thing here, but
Macros in Rust pt1 In the last blog post I introduced macros and some general issues. In this post I want to describe macros (and other syntactic tools) in Rust. In the next instalment, I'll go into
Design patterns in Rust Design patterns are "general reusable solutions to a commonly occurring problem within a given context in software design". Design patterns are a great way to describe some of the culture and
Mozilla Macros We're currently planning an overhaul of the syntax extension and macro systems in Rust. I thought it would be a good opportunity to cover some background on macros and some of the issues
Rustfmt-ing Rust Rustfmt is a tool for formatting Rust code. It has seen some rapid and impressive development over the last few months, thanks to some awesome contributions from @marcusklaas, @cassiersg, and several others. It
New blog This is my new blog location. Congratulations on finding it! This blog was previously at http://featherweightmusings.blogspot.com and you should check there for the archives.