(2025-08-21, 14:35)Peter Blomberg Wrote: The file format is modular, not recursive. Recursive would mean that the same file or callpath contained the same file twice.
The LDraw file format _is_ recursive. In the same way a tree is a recursive structure.
Or, if you prefer, you could have these LDraw files:
— 0.dat and 1.dat as primitives,
— 2.dat = 0.dat + 1.dat
— 3.dat = 1.dat + 2.dat
— …
— n+1.dat = n-1.dat + n.dat
If that looks familiar, it’s because it’s Fibonacci, the poster child of recursion

And, as Fibonacci, you can be naive and parse (calculate) the same things twice, or not. And the structures you need and the way you parse the files don’t only depend on the actions you want to minimize but on the info you need and, therefore, first of all, your purpose.