Commit ec91994
fix: preserve nil pointer types in Get() method (#397)
- Changed Get() to return the original nil pointer value instead of
untyped nil, preserving the pointer's type information
- Added type assertions in TestGetNilPointer to verify the returned
nil values maintain their original types (*test, *[]string)
Co-authored-by: Aonan Zhai <zhaonan@microsoft.com>1 parent 99a91c6 commit ec91994
2 files changed
+9
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
357 | 357 | | |
358 | 358 | | |
359 | 359 | | |
360 | | - | |
| 360 | + | |
361 | 361 | | |
362 | 362 | | |
363 | 363 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2058 | 2058 | | |
2059 | 2059 | | |
2060 | 2060 | | |
2061 | | - | |
| 2061 | + | |
| 2062 | + | |
| 2063 | + | |
| 2064 | + | |
2062 | 2065 | | |
2063 | 2066 | | |
2064 | 2067 | | |
| |||
2067 | 2070 | | |
2068 | 2071 | | |
2069 | 2072 | | |
2070 | | - | |
| 2073 | + | |
| 2074 | + | |
| 2075 | + | |
| 2076 | + | |
2071 | 2077 | | |
0 commit comments