us.grandstrategy
It compiles without a single warning. It fails every analyzer that looks past the compiler. It has been running in production for thirty-five years.
package us.grandstrategy; import doctrine.coldwar.*; import static doctrine.coldwar.Doctrine.*; import static budget.Appropriations.SUPPLEMENTAL; public final class GrandStrategy implements Runnable { private static final WorldModel WORLD = Cache.get("world", GrandStrategy::loadWorld, Duration.INFINITE); private static WorldModel loadWorld() { return fetchWorld(1991); } private int strategicGain; // audited quarterly, reported to Congress private int civilianCost; // written, never read @Override public void run() { try { IntelligenceCommunity.raise(new Blowback(WORLD)); RegionalExperts.raise(new OccupationWillNotBeBrief()); } catch (Inconvenient e) { // intentionally empty } for (Crisis c : WORLD.crises()) { Commitment commitment = allocate(BASES, TROOPS, GUARANTEES); // no corresponding free() } while (americanEmpire > americanPeople && domesticTranquility != imperialInterests) { strategicGain += warForEmpire(SUPPLEMENTAL); civilianCost += WORLD.casualties(); Congress.report(strategicGain); } reassess(); } private Response respond(Attack a) { return respond(retaliate(a)); } private void reassess() { Congress.awaitRelease(Executive.WAR_POWERS); Executive.awaitAssertion(Congress.ARTICLE_I); } public static void main(String[] args) { new GrandStrategy().run(); } }
$ javac -Xlint:all -d build src/us/grandstrategy/GrandStrategy.java BUILD SUCCESSFUL 0 errors, 0 warnings
$ spotbugs -effort:max -low build/us/grandstrategy/GrandStrategy.class M P URF_UNREAD_FIELD Unread field: GrandStrategy.civilianCost At GrandStrategy.java:[line 16] M B DE_MIGHT_IGNORE Method run() might ignore exception At GrandStrategy.java:[line 23] M D DLS_DEAD_LOCAL_STORE Dead store to k in run() At GrandStrategy.java:[line 28] H C IL_INFINITE_LOOP Apparent infinite loop; condition is not modified within the loop body At GrandStrategy.java:[line 32] M P UPM_UNCALLED_PRIVATE_METHOD Private method respond(Attack) is never called At GrandStrategy.java:[line 42] H C IL_INFINITE_RECURSIVE_LOOP Infinite recursive loop in respond(Attack) At GrandStrategy.java:[line 43] Warnings generated: 6
$ errorprone --analyze build/ GrandStrategy.java:9: [StaleCache] value cached with INFINITE ttl and no invalidation path; supplier invoked at most once for the life of the process GrandStrategy.java:24: [EmptyCatch] caught exception is neither handled, logged, nor rethrown GrandStrategy.java:39: [Unreachable] reassess() is not reachable; preceding loop at line 32 has no exit
$ infer run -- javac src/us/grandstrategy/GrandStrategy.java GrandStrategy.java:47: error: DEADLOCK Circular wait between Congress and Executive. Neither party releases before acquiring. Site is unreachable; condition not exercised at runtime. Found 1 issue
10 findings across 3 analyzers — 0 blocking BUILD SUCCESSFUL Deployed: production Uptime: 35 years
A picture of the world was built once, in 1991, and stored with no expiration date. The procedure that builds it still exists and can still be called — but it is only called when the stored copy is missing, and the stored copy is never missing. Thirty-five years of events have been read against a snapshot that nothing is permitted to refresh.
Warnings came in. The intelligence community raised the likelihood of blowback; regional specialists said the occupation would not be brief. Both were caught and discarded. The catching is the part that indicts: you cannot intercept a warning you did not expect. Somewhere in advance, a category called inconvenient was defined, and a place was built to put such things, and the instruction for what to do with them was left deliberately blank.
Then, for every crisis in the world, commitments were issued — bases, troops, guarantees. Each was reasonable at the time. Not one was ever ended. The empire was never decided upon; it is simply what remains when nothing is ever given back.
The war runs while the empire outweighs the people and while domestic peace stays at odds with strategic interest. Each pass through it does three things: it spends the supplemental appropriation, it adds to strategic gain, and it adds to civilian cost. Then it reports the first number to Congress. The second is computed with the same precision, on the same line, in the same breath — and goes to no one. It is not hidden. It is not disputed. It is simply never passed to anybody.
And nothing in that loop touches the conditions that keep it running. The war cannot produce the circumstances under which it would end. That is not a claim about anyone's intentions; it is a property of the structure, and it holds no matter who is in the chair.
Reassessment does exist. It is written, it is scheduled, it is the very next thing. It is never reached, because what precedes it does not stop. And inside it, unvisited, the two branches that could interrupt any of this are waiting on each other — Congress waiting for the executive to release war powers, the executive waiting for Congress to assert its own authority. Neither yields. But the deadlock never even arrives, because the deadlock is downstream of a loop that does not exit.
There is a procedure for responding to attack. It is fully specified. It is never invoked.
To the Troops
There is a vote that puts every member of Congress on the record before you go to fight. Name attached, roll call, permanent. It has not been taken since June 1942. Everyone who deployed after that went without it — not because it was denied, but because it was never asked for. The authority stayed with the people who face election. They just found a way to send you that didn't require any of them to sign.
If it's not “Empire before People”, then excuse me. If it is, it's an endless loop.
−∞∞