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

compilation failed with latest rust #6

Open
milyin opened this issue May 29, 2017 · 0 comments
Open

compilation failed with latest rust #6

milyin opened this issue May 29, 2017 · 0 comments

Comments

@milyin
Copy link

milyin commented May 29, 2017

When I tried to compile 'simple.rs' the following error appeared:

error: setters is a derive mode
--> src\main.rs:7:1
|
7 | #[setters(into)]
| ^^^^^^^^^^^^^^^^

When I commented out '#[setters(into)]' string the other error appeared:

error[E0428]: a type named Simple has already been defined in this module
--> src\main.rs:8:1
|
6 | #[derive(getters, setters)]
| ------- previous definition of Simple here
7 | //#[setters(into)]
8 | / struct Simple {
9 | | field: String,
10 | | }
| |_^ Simple already defined

error[E0308]: mismatched types
--> src\main.rs:15:17
|
15 | s.set_field("there");
| ^^^^^^^ expected struct std::string::String, found reference
|
= note: expected type std::string::String
found type &'static str
= help: here are some functions which might fulfill your needs:
- .escape_debug()
- .escape_default()
- .escape_unicode()
- .to_lowercase()
- .to_uppercase()

error: aborting due to previous error(s)
accessors-test.zip

@emk emk self-assigned this May 29, 2017
@emk emk removed their assignment Jan 26, 2020
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

No branches or pull requests

2 participants