Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable more warning flags, and fix more warnings #3065

Merged
merged 10 commits into from
Oct 18, 2024

Conversation

cebtenzzre
Copy link
Member

@cebtenzzre cebtenzzre commented Oct 9, 2024

Follow-up to #3039.

  • -Wunused-variable is now enabled. The three warnings seemed benign and were fixed.
  • Several unused parameters were removed or explicitly ignored, but there's something fishy about handleDownloadProgress (it's mixing up bytes over the wire with bytes on disk) so I have not yet enabled -Wunused-parameter.
  • One curious unused parameter was bool isServer - isServer=false and isServer=true actually both created a server chat. This parameter was replaced with a tag struct to prevent confusion.
  • -Wunused-function is now enabled. One curiously unused function was goHighlightingRules() - we were calling javaHighlightingRules() for Go instead. This has been fixed. Moved to chatviewtextprocessor: fix Go syntax highlighting #3080.
  • A (very spammy) -Wswitch warning was fixed in Kompute.
  • Two deprecation warnings about std::is_pod were fixed in usearch. This warning is doing its job—this is very suspicious code; it really shouldn't be skipping construction/destruction for "plain old data" but not for other types. But we're a downstream project, so we can replace this with its functional equivalent of trivial && standard_layout and move on.

@cebtenzzre cebtenzzre marked this pull request as ready for review October 9, 2024 18:04
Signed-off-by: Jared Van Bortel <jared@nomic.ai>
Signed-off-by: Jared Van Bortel <jared@nomic.ai>
Signed-off-by: Jared Van Bortel <jared@nomic.ai>
Constructing a Chat with isServer=false would do the wrong thing. In
C++, tag types are typically used for disambiguation of constructors.

Signed-off-by: Jared Van Bortel <jared@nomic.ai>
Signed-off-by: Jared Van Bortel <jared@nomic.ai>
Signed-off-by: Jared Van Bortel <jared@nomic.ai>
Signed-off-by: Jared Van Bortel <jared@nomic.ai>
Signed-off-by: Jared Van Bortel <jared@nomic.ai>
tokenize() no longer relies on n_past.

Signed-off-by: Jared Van Bortel <jared@nomic.ai>
This removes the BM25 change, which conflicts with a proper fix made on
main.
@cebtenzzre cebtenzzre merged commit c3357b7 into main Oct 18, 2024
4 of 18 checks passed
@cebtenzzre cebtenzzre deleted the jared/enable-more-warnings branch October 18, 2024 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants