Ranking Important Source Files in Godot Engine (3.0.2-stable)

Godot Engine (godotengine/godot on GitHub) is an open-source, primarily C++-based game engine. It supports both 2D and 3D. As a C++ programmer, I decided to generate a dependency graph of the #include “…” and try to determine the most important files in the graph. By doing so, I hope to uncover what files are important […]

Q: Why is Racket’s parsing system so complicated (Scheme)?

A: Circa 2016, Racket’s internal syntax representation system had to be revised because of macros, or “code rewriting” or “code-to-code procedures.” Matthew Flatt can explain in his paper, “Binding as Sets of Scopes” in POPL 2016, and also on his online notes on the new macro expander system for Racket (also formerly PLT Scheme). Q: […]

In Scheme, even your keywords could be redefined.

Over the past few months, I’ve started the¬†shaka-scheme¬†project for my senior project at the University of Hawaii at Manoa, and I wanted to highlight two pieces of code that recently changed our entire course of development: (define proc1 (lambda () (define define 1) (display “define is actually “) ; This doesn’t display a procedure literal… […]

C++: Template duck-typing in 30 lines

#include struct Duck { void quack(std::ostream& out) { out << “Quack!” << std::endl; } }; struct Platypus { void quack(std::ostream& out) { int* i = NULL; out << *i << std::endl; } }; template void do_quack(std::ostream& out, MaybeDuck duck) { duck.quack(out); } int main() { Duck duck; Platypus platypus; do_quack(std::cout, duck); do_quack(std::cout, platypus); } C++ […]