Skip to content

Commit a8b2b05

Browse files
committed
P-037 A2.2-4R6b: F-MEMBER repaired; the member bodies the legacy pass never visits reach the orphan carrier
A2.2-4's completeness oracle found (formal note §10.6.10, F-MEMBER, §10.1 case 3) that expression-bodied members, methods of struct, record, record struct and interface types, and property accessors reach neither carrier: the legacy pass enumerates ClassDeclarationSyntax members that are BaseMethodDeclarationSyntax with a block body, and the three A2.2-3P admission gates sit inside that loop. The owner ruled it a production completeness repair under one boundary: the legacy `functions[]` universe does not grow. The repair keeps that boundary. An independent enumeration, GuardedOnlyMembers, walks every TypeDeclarationSyntax and yields exactly the bodies the legacy loop does not read — an expression-bodied method-like member of a class, every method-like member of a struct, record, record struct or interface, every accessor with a body, an expression-bodied property or indexer (its getter) — after each tree's legacy class loop, so every earlier orphan keeps its place. GuardedOnlyAdmission records, as symbols, the same owned-parameter predicate and the same candidate families in the same order as the legacy loop admits for its own methods (by-value owned disposable parameters; a local created by `new`, rented from a pool, opened by a BCL factory, rented from a MemoryPool, or returned by a first-party disposable factory; a `using` local only as a MemoryPool owner); BuildGuardedFacts takes any member declaration and any body (a block or an arrow clause; MethodSymbolOf resolves an expression-bodied property to its getter) and the result rides in `guarded_functions[]`. No legacy structure, gate or lowering input changes, and no member enumerated here ever had a `functions[]` record, so the carrier's identity refusal cannot fire. Lambdas and local functions stay the separate nested-function gap. Measured on this tree: the 53 census shapes read byte-identical and two new shapes pin the repair (orphan-expression-bodied, orphan-struct-method); the probe re-measured into a2_2_4r6_observed moves no row while its helper Box.op_Implicit, an expression-bodied conversion operator, now carries its object_creation fact as an orphan and the probe reads RED-free; the six member-* witnesses read green with carrier guarded_functions; the oracle raises no RED over any input, so the findings ledger's expected_red is empty and F-MEMBER moves to `closed`; the inertness control and the local rehearsal against the T before-takes are unchanged on both engines. Same instrument, no new T/R. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QfeUtLRm6KFRWcTGQZxQQb
1 parent 63810bb commit a8b2b05

19 files changed

Lines changed: 568 additions & 125 deletions

File tree

‎corpus/p037-hostile/cases/member-accessor.cs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// GENERATED by scripts/p037_hostile_census.py (P-037 A2.2-4 hostile census); do not edit.
2-
// member kind: a property setter passing its `value` parameter; accessors are not BaseMethodDeclarationSyntax and are never visited (finding F-MEMBER)
2+
// member kind: a property setter passing its `value` parameter; accessors are not BaseMethodDeclarationSyntax and are never visited (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)
33
using System;
44
using System.IO;
55
using System.Collections.Generic;

‎corpus/p037-hostile/cases/member-default-interface-method.cs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// GENERATED by scripts/p037_hostile_census.py (P-037 A2.2-4 hostile census); do not edit.
2-
// member kind: a default interface method with a body; the legacy pass enumerates class declarations only, and the root cause is the enumeration, not struct-ness (finding F-MEMBER)
2+
// member kind: a default interface method with a body; the legacy pass enumerates class declarations only, and the root cause is the enumeration, not struct-ness (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)
33
using System;
44
using System.IO;
55
using System.Collections.Generic;

‎corpus/p037-hostile/cases/member-expression-bodied.cs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// GENERATED by scripts/p037_hostile_census.py (P-037 A2.2-4 hostile census); do not edit.
2-
// member kind: an expression-bodied method with an owned parameter; the legacy pass visits block bodies only, so neither carrier sees the call (finding F-MEMBER)
2+
// member kind: an expression-bodied method with an owned parameter; the legacy pass visits block bodies only, so neither carrier sees the call (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)
33
using System;
44
using System.IO;
55
using System.Collections.Generic;

‎corpus/p037-hostile/cases/member-record-struct.cs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// GENERATED by scripts/p037_hostile_census.py (P-037 A2.2-4 hostile census); do not edit.
2-
// member kind: a method of a record struct; neither a class declaration nor a record class (finding F-MEMBER)
2+
// member kind: a method of a record struct; neither a class declaration nor a record class (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)
33
using System;
44
using System.IO;
55
using System.Collections.Generic;

‎corpus/p037-hostile/cases/member-record.cs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// GENERATED by scripts/p037_hostile_census.py (P-037 A2.2-4 hostile census); do not edit.
2-
// member kind: a method of a record; the legacy pass enumerates class declarations only (finding F-MEMBER)
2+
// member kind: a method of a record; the legacy pass enumerates class declarations only (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)
33
using System;
44
using System.IO;
55
using System.Collections.Generic;

‎corpus/p037-hostile/cases/member-struct.cs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// GENERATED by scripts/p037_hostile_census.py (P-037 A2.2-4 hostile census); do not edit.
2-
// member kind: a method of a struct; the legacy pass enumerates class declarations only (finding F-MEMBER)
2+
// member kind: a method of a struct; the legacy pass enumerates class declarations only (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)
33
using System;
44
using System.IO;
55
using System.Collections.Generic;

‎corpus/p037-hostile/expected.json‎

Lines changed: 18 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@
319319
"member-accessor": {
320320
"member": "H_member_accessor.M",
321321
"member_override": ".set_Slot",
322-
"carrier": "none",
322+
"carrier": "guarded_functions",
323323
"occurrences": [
324324
{
325325
"symbol": "value",
@@ -329,16 +329,13 @@
329329
"expected": "param"
330330
}
331331
],
332-
"red": {
333-
"occurrence_not_captured": 1
334-
},
335-
"finding": "F-MEMBER",
336-
"why": "member kind: a property setter passing its `value` parameter; accessors are not BaseMethodDeclarationSyntax and are never visited (finding F-MEMBER)"
332+
"red": {},
333+
"why": "member kind: a property setter passing its `value` parameter; accessors are not BaseMethodDeclarationSyntax and are never visited (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)"
337334
},
338335
"member-default-interface-method": {
339336
"member": "H_member_default_interface_method.M",
340337
"member_override": ".IHolder.M",
341-
"carrier": "none",
338+
"carrier": "guarded_functions",
342339
"occurrences": [
343340
{
344341
"symbol": "r",
@@ -348,15 +345,12 @@
348345
"expected": "param"
349346
}
350347
],
351-
"red": {
352-
"occurrence_not_captured": 1
353-
},
354-
"finding": "F-MEMBER",
355-
"why": "member kind: a default interface method with a body; the legacy pass enumerates class declarations only, and the root cause is the enumeration, not struct-ness (finding F-MEMBER)"
348+
"red": {},
349+
"why": "member kind: a default interface method with a body; the legacy pass enumerates class declarations only, and the root cause is the enumeration, not struct-ness (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)"
356350
},
357351
"member-expression-bodied": {
358352
"member": "H_member_expression_bodied.M",
359-
"carrier": "none",
353+
"carrier": "guarded_functions",
360354
"occurrences": [
361355
{
362356
"symbol": "r",
@@ -366,11 +360,8 @@
366360
"expected": "param"
367361
}
368362
],
369-
"red": {
370-
"occurrence_not_captured": 1
371-
},
372-
"finding": "F-MEMBER",
373-
"why": "member kind: an expression-bodied method with an owned parameter; the legacy pass visits block bodies only, so neither carrier sees the call (finding F-MEMBER)"
363+
"red": {},
364+
"why": "member kind: an expression-bodied method with an owned parameter; the legacy pass visits block bodies only, so neither carrier sees the call (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)"
374365
},
375366
"member-local-function": {
376367
"member": "H_member_local_function.M",
@@ -389,7 +380,7 @@
389380
"member-record": {
390381
"member": "H_member_record.M",
391382
"member_override": ".Holder.M",
392-
"carrier": "none",
383+
"carrier": "guarded_functions",
393384
"occurrences": [
394385
{
395386
"symbol": "r",
@@ -399,16 +390,13 @@
399390
"expected": "param"
400391
}
401392
],
402-
"red": {
403-
"occurrence_not_captured": 1
404-
},
405-
"finding": "F-MEMBER",
406-
"why": "member kind: a method of a record; the legacy pass enumerates class declarations only (finding F-MEMBER)"
393+
"red": {},
394+
"why": "member kind: a method of a record; the legacy pass enumerates class declarations only (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)"
407395
},
408396
"member-record-struct": {
409397
"member": "H_member_record_struct.M",
410398
"member_override": ".Holder.M",
411-
"carrier": "none",
399+
"carrier": "guarded_functions",
412400
"occurrences": [
413401
{
414402
"symbol": "r",
@@ -418,16 +406,13 @@
418406
"expected": "param"
419407
}
420408
],
421-
"red": {
422-
"occurrence_not_captured": 1
423-
},
424-
"finding": "F-MEMBER",
425-
"why": "member kind: a method of a record struct; neither a class declaration nor a record class (finding F-MEMBER)"
409+
"red": {},
410+
"why": "member kind: a method of a record struct; neither a class declaration nor a record class (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)"
426411
},
427412
"member-struct": {
428413
"member": "H_member_struct.M",
429414
"member_override": ".Holder.M",
430-
"carrier": "none",
415+
"carrier": "guarded_functions",
431416
"occurrences": [
432417
{
433418
"symbol": "r",
@@ -437,11 +422,8 @@
437422
"expected": "param"
438423
}
439424
],
440-
"red": {
441-
"occurrence_not_captured": 1
442-
},
443-
"finding": "F-MEMBER",
444-
"why": "member kind: a method of a struct; the legacy pass enumerates class declarations only (finding F-MEMBER)"
425+
"red": {},
426+
"why": "member kind: a method of a struct; the legacy pass enumerates class declarations only (F-MEMBER, repaired in A2.2-4R6: the orphan carrier holds the fact)"
445427
},
446428
"pw-ctor-array-params-orphan-local": {
447429
"member": "H_pw_ctor_array_params_orphan_local.M",

‎corpus/p037-relevance/oracle_findings.json‎

Lines changed: 9 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,8 @@
11
{
22
"schema": "p037-oracle-findings/1",
33
"why": "Every RED the completeness oracle (frontend/roslyn/OwnSharp.Oracle) is EXPECTED to raise, tied to a finding classified by docs/notes/p037-formal-kernel.md \u00a710.1. An input absent from expected_red must be RED-free; an input present must raise exactly these kinds and counts. A finding closes only by a ruling or a separately classified change that removes its RED, and the entry with it.",
4-
"findings": {
5-
"F-MEMBER": {
6-
"class": "case 3",
7-
"title": "member bodies the legacy pass never visits: expression-bodied members, methods of struct and record types, property accessors",
8-
"evidence": "Program.cs enumerates ClassDeclarationSyntax only and, inside it, BaseMethodDeclarationSyntax with a block Body; the three A2.2-3P admission gates sit inside that loop, so these members reach neither functions[] nor guarded_functions[]. Witnessed by the probe (Box.op_Implicit, an expression-bodied conversion operator) and by four hostile cases.",
9-
"status": "open: a census finding; carrying these members in the orphan carrier is a production change to be classified on its own",
10-
"red": "occurrence_not_captured"
11-
}
12-
},
13-
"expected_red": {
14-
"probe": {
15-
"red": {
16-
"occurrence_not_captured": 1
17-
},
18-
"finding": "F-MEMBER",
19-
"member": "Probe.Box.op_Implicit"
20-
}
21-
},
4+
"findings": {},
5+
"expected_red": {},
226
"closed": {
237
"F-SHADOW": {
248
"class": "case 1",
@@ -54,6 +38,13 @@
5438
"evidence": "`Holder(MemoryStream r) : base(r, true)` passes the owned parameter into a really invoked constructor's declared ordinal 0, the same ownership edge object_creation was added for; the frozen vocabulary has no call_kind for a ConstructorInitializerSyntax site, so no fact exists and the oracle reads the occurrence as unclassified. Ruled in A2.2-4R4 to be a fact shape (call_kind constructor_initializer; site the initializer; callee the target constructor's {Type}..ctor key; sig its canonical signature; arguments bound to the target constructor's declared ordinals; first_party by declaring syntax; the same value-flow and binding machinery), landing in A2.2-4R5. Witnessed by the hostile case vocab-constructor-initializer.",
5539
"status": "closed: A2.2-4R5. call_kind constructor_initializer; the initializer's argument syntax is visited for nested call sites too; three hostile witnesses and the census shape sidecar-ctorinit-base are green; the probe row CtorInit reads orphan_call:constructor_initializer.",
5640
"red": "unclassified_argument_shape:constructor_initializer"
41+
},
42+
"F-MEMBER": {
43+
"class": "case 3",
44+
"title": "member bodies the legacy pass never visits: expression-bodied members, methods of struct and record types, property accessors",
45+
"evidence": "Program.cs enumerates ClassDeclarationSyntax only and, inside it, BaseMethodDeclarationSyntax with a block Body; the three A2.2-3P admission gates sit inside that loop, so these members reach neither functions[] nor guarded_functions[]. Witnessed by the probe (Box.op_Implicit, an expression-bodied conversion operator) and by four hostile cases.",
46+
"status": "closed: A2.2-4R6. An independent guarded-only member enumeration (expression-bodied members of a class, every method-like member of a struct, record, record struct or interface, property and indexer accessors) feeds BuildGuardedFacts and the orphan carrier; the legacy enumeration and functions[] are untouched. Six hostile witnesses and the probe's Box.op_Implicit read green; lambdas and local functions stay the separate nested-function gap.",
47+
"red": "occurrence_not_captured"
5748
}
5849
}
5950
}

0 commit comments

Comments
 (0)