We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
_t
1 parent 7fd17ba commit da47eb0Copy full SHA for da47eb0
CONTRIBUTING.md
@@ -74,7 +74,16 @@
74
75
- Declare structs with `struct x {}` instead of `typedef struct x {} x`
76
- In C++ code omit the `struct` keyword whenever it is not necessary
77
- - Use `_t` suffix when ...
+ - Use the `_t` suffix when the types are supposed to be opaque to the user - it's not relevant to them if it is a struct or anything else
78
+
79
+ ```cpp
80
+ typedef struct llama_context * llama_context_t;
81
82
+ enum llama_pooling_type llama_pooling_type(const llama_context_t ctx);
83
+ ```
84
85
+ > [!NOTE]
86
+ > This guideline is yet to be applied to the `llama.cpp` codebase. New code should follow this guideline.
87
88
- Follow the existing code style, in case of doubt use `clang-format` to format the added code
89
0 commit comments