avoid `raises: [Defect]` on nim 1.4+

This commit is contained in:
Jacek Sieka 2023-02-21 09:42:23 +01:00
parent 1c8a822274
commit c9f77af179
2 changed files with 460 additions and 455 deletions

File diff suppressed because it is too large Load Diff

View File

@ -22,8 +22,9 @@ nim c -o:wrap --verbosity:0 --hints:off ./sqlite3_abi/wrap.nim
./wrap
sed -i \
-e "s|cdecl|cdecl, raises: [Defect]|g" \
-e "s|cdecl|sqlitedecl|g" \
-e "s|$PWD/||" \
-e 's|{.experimental: "codeReordering".}|{.experimental: "codeReordering".}\nwhen (NimMajor, NimMinor) < (1, 4):\n {.pragma: sqlitedecl, cdecl, raises: [Defect].}\nelse:\n {.pragma: sqlitedecl, cdecl, raises: [].}|' \
-e "s|sqlite3_column_text\\*(a1: ptr sqlite3_stmt; iCol: cint): ptr cuchar|sqlite3_column_text\\*(a1: ptr sqlite3_stmt; iCol: cint): cstring|" \
-e "s|sqlite3_value_text\\*(a1: ptr sqlite3_value): ptr cuchar|sqlite3_value_text\\*(a1: ptr sqlite3_value): cstring|" \
sqlite3_abi/sqlite3_gen.nim