1+++
2repository_url = "https://github.com/zed-industries/codex-acp"
3revision = "c3d24ee70928fc9da08c131fc632d624413ccc43"
4+++
5
6## Edit History
7
8```diff
9--- a/src/prompt_args.rs
10+++ b/src/prompt_args.rs
11@@ -28,7 +28,7 @@ impl PromptArgsError {
12 }
13 }
14
15-#[derive(Debug)]
16+#[derive(Debug, Serialize)]
17 pub enum PromptExpansionError {
18 Args {
19 command: String,
20```
21
22## Cursor Position
23
24```src/prompt_args.rs
25#[derive(Debug)]
26pub enum PromptArgsError {
27// ^[CURSOR_POSITION]
28 MissingAssignment { token: String },
29 MissingKey { token: String },
30}
31```
32
33## Expected Patch
34
35```diff
36--- a/src/prompt_args.rs
37+++ b/src/prompt_args.rs
38@@ -9,7 +9,7 @@ use std::sync::LazyLock;
39 static PROMPT_ARG_REGEX: LazyLock<Regex> =
40 LazyLock::new(|| Regex::new(r"\$[A-Z][A-Z0-9_]*").unwrap_or_else(|_| std::process::abort()));
41
42-#[derive(Debug)]
43+#[derive(Debug, Serialize)]
44 pub enum PromptArgsError {
45 MissingAssignment { token: String },
46 MissingKey { token: String },
47```
48
49```diff
50--- a/src/prompt_args.rs
51+++ b/src/prompt_args.rs
52@@ -3,19 +3,20 @@
53 use regex_lite::Regex;
54+use serde::Serialize;
55 use shlex::Shlex;
56 use std::collections::HashMap;
57 use std::collections::HashSet;
58 use std::sync::LazyLock;
59
60 static PROMPT_ARG_REGEX: LazyLock<Regex> =
61 LazyLock::new(|| Regex::new(r"\$[A-Z][A-Z0-9_]*").unwrap_or_else(|_| std::process::abort()));
62
63-#[derive(Debug)]
64+#[derive(Debug, Serialize)]
65 pub enum PromptArgsError {
66 MissingAssignment { token: String },
67 MissingKey { token: String },
68 }
69```