Skip to content

Instantly share code, notes, and snippets.

View astocko's full-sized avatar
💭
I may be slow to respond.

Alexander Stocko astocko

💭
I may be slow to respond.
View GitHub Profile
@bsilver8192
bsilver8192 / BUILD
Created March 17, 2016 16:12
Basics of generating a compile_commands.json file with Bazel
py_binary(
name = 'generate_compile_command',
srcs = [
'generate_compile_command.py',
],
deps = [
'//third_party/bazel:extra_actions_proto_py',
],
)
@kevinmehall
kevinmehall / test_extctxt.rs
Last active November 2, 2019 18:59
Rust: Creating a ExtCtxt for quasiquote outside of a syntax extension
#![feature(quote)]
extern crate syntax;
use syntax::print::pprust;
use syntax::codemap::DUMMY_SP;
fn main() {
with_fake_extctxt(|cx| {
let x = quote_expr!(cx, (a+b));