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

error: bad operand types for binary operator '+' #113

Closed
asolntsev opened this issue Oct 20, 2021 · 3 comments · Fixed by #115
Closed

error: bad operand types for binary operator '+' #113

asolntsev opened this issue Oct 20, 2021 · 3 comments · Fixed by #115
Labels
bug Something isn't working
Milestone

Comments

@asolntsev
Copy link

asolntsev commented Oct 20, 2021

I created a record with String and int parameters.
But I am getting a compilation error on it:

> Task :example:compileJava
Jabel: initialized
/Users/andrei/projects/jabel/example/src/main/java/com/example/Browser.java:1: error: bad operand types for binary operator '+'
package com.example;
^
  first type:  int
  second type: boolean
1 error

> Task :example:compileJava FAILED

The source code:

package com.example;

import com.github.bsideup.jabel.Desugar;

@Desugar
record Browser(String name, boolean headless) {
}

NB! I added a code reproducing the issue: #114

@bsideup
Copy link
Owner

bsideup commented Oct 20, 2021

Hi @asolntsev,

Thanks for reporting, and I am sorry for this stupid miss! Fixed in #115. Will merge once green and make a release (that also dramatically improves the performance, see #101)

@bsideup bsideup added the bug Something isn't working label Oct 20, 2021
@bsideup
Copy link
Owner

bsideup commented Oct 20, 2021

Tagged https://github.com/bsideup/jabel/releases/tag/0.4.2 , will release to Maven Central soon (you can use Jitpack to try it for now)

@bsideup
Copy link
Owner

bsideup commented Oct 21, 2021

Released in 0.4.2 👍

@bsideup bsideup added this to the next milestone Oct 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants