midnight-mcp 0.1.35 → 0.1.36

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -351,5 +351,12 @@ witness lookup_value(key: Bytes<32>): Field;`,
351
351
  2. Range check fails (use bounded Uint)
352
352
  3. Logic error in circuit`,
353
353
  },
354
+ {
355
+ error: 'parse error: found ":" looking for ")"',
356
+ cause: "Using Rust-style :: for enum variant access",
357
+ fix: `Use dot notation for enum variants:
358
+ WRONG: Choice::rock, GameState::waiting
359
+ CORRECT: Choice.rock, GameState.waiting`,
360
+ },
354
361
  ];
355
362
  //# sourceMappingURL=compact-version.js.map
@@ -133,6 +133,16 @@ export enum GameState { waiting, playing, finished }
133
133
  export enum Choice { rock, paper, scissors }
134
134
  \`\`\`
135
135
 
136
+ **Enum Access Syntax** - use DOT notation (not Rust-style ::):
137
+ \`\`\`compact
138
+ // CORRECT - dot notation
139
+ if (choice == Choice.rock) { ... }
140
+ game_state = GameState.waiting;
141
+
142
+ // WRONG - Rust-style double colon
143
+ if (choice == Choice::rock) { ... } // ❌ Parse error: found ":" looking for ")"
144
+ \`\`\`
145
+
136
146
  **Structs**:
137
147
  \`\`\`compact
138
148
  export struct PlayerConfig {
@@ -411,6 +411,11 @@ export circuit increment(): [] {
411
411
  correct: "// Use witness: witness get_value(key): Type;",
412
412
  error: "member access requires struct type",
413
413
  },
414
+ {
415
+ wrong: "Choice::rock (Rust-style)",
416
+ correct: "Choice.rock (dot notation)",
417
+ error: 'parse error: found ":" looking for ")"',
418
+ },
414
419
  ],
415
420
  syntaxReference: compactReference,
416
421
  sections: [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "midnight-mcp",
3
- "version": "0.1.35",
3
+ "version": "0.1.36",
4
4
  "description": "Model Context Protocol Server for Midnight Blockchain Development",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",