linksplatform / Solver

Algorithms to find shortest and simplest possible functions for given input and output data ranges.
The Unlicense
2 stars 1 forks source link

Unable to compile #7

Open Konard opened 1 year ago

Konard commented 1 year ago
gitpod /workspace/Solver (main) $ cargo run
   Compiling solver v0.1.0 (/workspace/Solver)
error[E0412]: cannot find type `Link` in this scope
  --> src/main.rs:70:75
   |
70 | fn get_link_by_id(store: &mut unit::Store<usize, _>, id: usize) -> Result<Link<usize>, Error<usize>> {
   |                                                                           ^^^^
   |
  ::: /workspace/.cargo/git/checkouts/doublets-rs-3835f06948971044/a35ee5b/doublets/src/data/traits.rs:16:1
   |
16 | pub trait Links<T: LinkType>: Send + Sync {
   | ----------------------------------------- similarly named trait `Links` defined here
   |
help: a trait with a similar name exists
   |
70 | fn get_link_by_id(store: &mut unit::Store<usize, _>, id: usize) -> Result<Links<usize>, Error<usize>> {
   |                                                                           ~~~~~
help: consider importing this struct
   |
1  | use doublets::Link;
   |

error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
  --> src/main.rs:70:50
   |
70 | fn get_link_by_id(store: &mut unit::Store<usize, _>, id: usize) -> Result<Link<usize>, Error<usize>> {
   |                                                  ^ not allowed in type signatures
   |
help: use type parameters instead
   |
70 | fn get_link_by_id<T>(store: &mut unit::Store<usize, T>, id: usize) -> Result<Link<usize>, Error<usize>> {
   |                  +++                                ~

Some errors have detailed explanations: E0121, E0412.
For more information about an error, try `rustc --explain E0121`.
error: could not compile `solver` due to 2 previous errors
Checklist - [X] `src/main.rs` βœ… Commit [`0227f26`](https://github.com/linksplatform/Solver/commit/0227f261d10de0b132173e9ab014ebc86c89b189)
linksplatform-sweepai[bot] commented 1 year ago

Here's the PR! https://github.com/linksplatform/Solver/pull/9.

πŸ’Ž Sweep Pro: I'm creating this ticket using GPT-4. You have unlimited GPT-4 tickets.

Actions (click)


Step 1: πŸ”Ž Searching

I found the following snippets in your repository. I will now analyze these snippets and come up with a plan.

Some code snippets I looked at (click to expand). If some file is missing from here, you can mention the path in the ticket description.

Step 2: ⌨️ Coding


Step 3: πŸ” Code Review

I have finished reviewing the code for completeness. I did not find errors for sweep/fix-compilation-errors.

.


πŸŽ‰ Latest improvements to Sweep:


πŸ’‘ To recreate the pull request edit the issue title or description. To tweak the pull request, leave a comment on the pull request. Join Our Discord