 
      
    | You are here | blog.logrocket.com | ||
| | | | | poignardazur.github.io | |
| | | | | [Note - This is republishing of an article that was previous posted on github gist, and advertised on reddit in January 2021.] | |
| | | | | mbuffett.com | |
| | | | | Recently I've been working on a project to surface census data via a GraphQL API, mostly as a way to learn GraphQL. I did end up learning GraphQL, but I also ended up learning a lot about proc macros. I was using Juniper, which creates a GraphQL schema using structs like this: #[derive(GraphQLObject, Copy, Clone, Debug)] struct Demographics { female: Option, male: Option, } The problem, is that the census data I was looking to surface had way too many variables, I would have had to write out 207 structs, with a total of 352 fields. Here's a nice tree-view of the census data, courtesy of the frangipanni tool. Obviously, I didn't want to write out all these structs and fields by hand, even with some fancy vim macros that would have been too much tedious work for a side project that's supposed to be fun. | |
| | | | | blog.m-ou.se | |
| | | | | About a year ago, I published a Rust crate called inline-python, which allows you to easily mix some Python into your Rust code using a python!{ .. } macro. In this series, I'll go through the process of developing this crate from scratch. | |
| | | | | benoitpasquier.com | |
| | | For the past few years, I had the opportunity to mentor new joiners through different roles. In some aspects, I could see myself in them the same way I started years back: eager to prove themselves, jumping on the code and hacking around. I tried to think about what I learnt the hard way since my first role in the tech industry and how could I help them learn the easy way. | ||