
# 处理 null 值 - 实现计划 (分解和优先级任务列表)

## [x] 任务 1: 找到处理 null 值被错误转换的代码位置
- **Priority**: P0
- **Depends On**: None
- **Description**: 
  - 分析 CSharpStringExtractor.ts 中的代码，找到添加 .TR() 后缀的关键位置
  - 主要检查 processTextAssignments 和 processStatementAndExtractValue 等方法
- **Acceptance Criteria Addressed**: [AC-1]
- **Test Requirements**:
  - `programmatic` TR-1.1: 找到所有可能添加 .TR() 的方法 ✓
- **Notes**: 特别注意 .text 赋值处理的代码路径

## [x] 任务 2: 修改相关方法，对 null 值进行特殊处理
- **Priority**: P0
- **Depends On**: ["任务 1"]
- **Description**: 
  - 在添加 .TR() 后缀的代码之前，检查值是否为 null
  - 如果是 null，就跳过转换，保持原样
- **Acceptance Criteria Addressed**: [AC-1]
- **Test Requirements**:
  - `programmatic` TR-2.1: 在 processTextAssignments 中添加 null 检查 ✓
  - `programmatic` TR-2.2: 在 processStringConcatenation 中添加 null 检查 ✓
  - `programmatic` TR-2.3: 在其他相关方法中添加 null 检查（如果需要）
- **Notes**: 只修改与添加 .TR() 相关的逻辑

## [x] 任务 3: 验证修复是否解决了问题
- **Priority**: P0
- **Depends On**: ["任务 2"]
- **Description**: 
  - 运行目标测试用例 "should handle null"
  - 确保测试通过
  - 运行完整的测试套件，确保其他测试没有受到影响
- **Acceptance Criteria Addressed**: [AC-1]
- **Test Requirements**:
  - `programmatic` TR-3.1: "should handle null" 测试用例通过 ✓
  - `programmatic` TR-3.2: 所有其他现有测试继续通过（无回归）
- **Notes**: 使用 Jest 运行完整测试套件

