A Golang runtime and compilation backend for Delta Interaction Nets.

fmt

+9 -9
+5 -5
cmd/gentests/tests/103_confluence/reduction_test.go
··· 20 20 // "Since all normal Delta-nets are canonical, the Delta-Nets systems are all Church-Rosser confluent." 21 21 // 22 22 // This test validates that: 23 - // 1. All reduction paths lead to the same canonical form 24 - // 2. The canonical form is independent of reduction order 25 - // 3. The two-phase reduction strategy (Phase 1: LMO + Canonicalization, Phase 2: Aux Fan Replication) 26 - // produces a canonical result 23 + // 1. All reduction paths lead to the same canonical form 24 + // 2. The canonical form is independent of reduction order 25 + // 3. The two-phase reduction strategy (Phase 1: LMO + Canonicalization, Phase 2: Aux Fan Replication) 26 + // produces a canonical result 27 27 func Test_103_confluence(t *testing.T) { 28 28 // Parse the input term 29 29 term, err := lambda.Parse(input) ··· 220 220 t.Log(" - Sequential pop from priority queues") 221 221 t.Log(" - Global reduction mutex") 222 222 t.Log(" - Depth increment for internal structure") 223 - } 223 + }
+2 -2
pkg/deltanet/deltanet.go
··· 884 884 if w == nil { 885 885 continue 886 886 } 887 - 887 + 888 888 // Lock wire to inspect neighbor safely 889 889 w.mu.Lock() 890 890 if p.Wire.Load() != w { 891 891 w.mu.Unlock() 892 892 continue 893 893 } 894 - 894 + 895 895 other := w.Other(p) 896 896 if other == nil { 897 897 w.mu.Unlock()
+2 -2
pkg/deltanet/scheduler.go
··· 40 40 // Lock to ensure only one worker pops at a time, 41 41 // guaranteeing strict leftmost-outermost order 42 42 s.mu.Lock() 43 - 43 + 44 44 // Scan for highest priority (lowest depth index) 45 45 for i := 0; i < MaxPriority; i++ { 46 46 select { ··· 51 51 continue 52 52 } 53 53 } 54 - 54 + 55 55 // No work found, unlock and wait for signal 56 56 s.mu.Unlock() 57 57 <-s.signal