瀏覽代碼

tests : free llama context at the end of the test

Georgi Gerganov 2 年之前
父節點
當前提交
d502bc7c9d
共有 2 個文件被更改,包括 4 次插入1 次删除
  1. 2 1
      CMakeLists.txt
  2. 2 0
      tests/test-tokenizer-0.cpp

+ 2 - 1
CMakeLists.txt

@@ -129,13 +129,14 @@ if (LLAMA_ALL_WARNINGS)
             -Wshadow
             -Wstrict-prototypes
             -Wpointer-arith
+            -Wno-unused-function
         )
         set(cxx_flags
             -Wall
             -Wextra
             -Wpedantic
             -Wcast-qual
-            -Wdouble-promotion
+            -Wno-unused-function
         )
     else()
         # todo : msvc

+ 2 - 0
tests/test-tokenizer-0.cpp

@@ -77,5 +77,7 @@ int main(int argc, char **argv) {
         }
     }
 
+    llama_free(ctx);
+
     return 0;
 }