MCPcopy Create free account
hub / github.com/URLab-Sim/UnrealRoboticsLab / step_parse

Function step_parse

Scripts/generate_docs.py:69–85  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

67# ──────────────────────────────────────────────────────────────────────────────
68
69def step_parse():
70 print("\n─── Step 1: Parsing C++ headers ───")
71 sys.path.insert(0, SCRIPT_DIR)
72 from parse_headers import scan_public_headers # type: ignore
73
74 data = scan_public_headers(PUBLIC_ROOT)
75
76 # Count totals
77 total_classes = sum(len(pf.get('classes', [])) for pf in data)
78 total_enums = sum(len(pf.get('enums', [])) for pf in data)
79 print(f" ✓ Scanned {len(data)} files → {total_classes} classes/structs, {total_enums} enums")
80
81 os.makedirs(DOCS_ROOT, exist_ok=True)
82 with open(PARSED_JSON, 'w', encoding='utf-8') as f:
83 json.dump(data, f, indent=2)
84 print(f" ✓ Saved parsed data → {os.path.relpath(PARSED_JSON, PLUGIN_ROOT)}")
85 return data
86
87# ──────────────────────────────────────────────────────────────────────────────
88# Step 2 — Emit Markdown

Callers 1

mainFunction · 0.85

Calls 1

scan_public_headersFunction · 0.90

Tested by

no test coverage detected