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

Maven compiles different then Eclipse for staticConstructor #136

Closed
lombokissues opened this Issue Jul 14, 2015 · 4 comments

Comments

Projects
None yet
1 participant
@lombokissues
Collaborator

lombokissues commented Jul 14, 2015

Migrated from Google Code (issue 63)

@lombokissues

This comment has been minimized.

Show comment
Hide comment
@lombokissues

lombokissues Jul 14, 2015

Collaborator

👤 nick.stolwijk   🕗 Oct 26, 2009 at 15:39 UTC

What steps will reproduce the problem?

  1. Create a simple project with Maven and add Lombock as dependency and
    configure the compiler plugin to use Javac v1.6
  2. Create a simple class with @ Data(staticConstructor="of")
  3. Run mvn clean install
  4. Check the compiled class with javap:

public class com.example.lombok.model.Car extends java.lang.Object{
public java.lang.String getLicense();
public java.lang.String toString();
public int hashCode();
public boolean equals(java.lang.Object);
static com.example.lombok.model.Car of(java.lang.String);
}

  1. Load your project into Eclipse(Lombok was added)
  2. Let Eclipse compile your class
  3. Check the compiled class with javap:

public class com.example.lombok.model.Car extends java.lang.Object{
public java.lang.String getLicense();
public java.lang.String toString();
public int hashCode();
public boolean equals(java.lang.Object);
public static com.example.lombok.model.Car of(java.lang.String);
}

What is the expected output? What do you see instead?
Expected: a public static function
Actual: a package protected static function

What version of the product are you using? On what operating system?
Lombok 0.8.5
Eclipse 3.5
Kubuntu 9.04
java version "1.6.0_16"
Java(TM) SE Runtime Environment (build 1.6.0_16-b01)
Java HotSpot(TM) Client VM (build 14.2-b01, mixed mode, sharing)

Please provide any additional information below.

Collaborator

lombokissues commented Jul 14, 2015

👤 nick.stolwijk   🕗 Oct 26, 2009 at 15:39 UTC

What steps will reproduce the problem?

  1. Create a simple project with Maven and add Lombock as dependency and
    configure the compiler plugin to use Javac v1.6
  2. Create a simple class with @ Data(staticConstructor="of")
  3. Run mvn clean install
  4. Check the compiled class with javap:

public class com.example.lombok.model.Car extends java.lang.Object{
public java.lang.String getLicense();
public java.lang.String toString();
public int hashCode();
public boolean equals(java.lang.Object);
static com.example.lombok.model.Car of(java.lang.String);
}

  1. Load your project into Eclipse(Lombok was added)
  2. Let Eclipse compile your class
  3. Check the compiled class with javap:

public class com.example.lombok.model.Car extends java.lang.Object{
public java.lang.String getLicense();
public java.lang.String toString();
public int hashCode();
public boolean equals(java.lang.Object);
public static com.example.lombok.model.Car of(java.lang.String);
}

What is the expected output? What do you see instead?
Expected: a public static function
Actual: a package protected static function

What version of the product are you using? On what operating system?
Lombok 0.8.5
Eclipse 3.5
Kubuntu 9.04
java version "1.6.0_16"
Java(TM) SE Runtime Environment (build 1.6.0_16-b01)
Java HotSpot(TM) Client VM (build 14.2-b01, mixed mode, sharing)

Please provide any additional information below.

@lombokissues

This comment has been minimized.

Show comment
Hide comment
@lombokissues

lombokissues Jul 14, 2015

Collaborator

👤 reinierz   🕗 Nov 01, 2009 at 23:45 UTC

Hey, whoops. Yeah, that's a bug. It's been fixed in v0.9.0. which is about to be released.

Fixed in 4eea52f

Collaborator

lombokissues commented Jul 14, 2015

👤 reinierz   🕗 Nov 01, 2009 at 23:45 UTC

Hey, whoops. Yeah, that's a bug. It's been fixed in v0.9.0. which is about to be released.

Fixed in 4eea52f

@lombokissues

This comment has been minimized.

Show comment
Hide comment
@lombokissues

lombokissues Jul 14, 2015

Collaborator

👤 reinierz   🕗 Nov 02, 2009 at 00:12 UTC

v0.9.0 has been rolled out! Go ahead and tell maven to update your dependencies to v0.9.0.

Collaborator

lombokissues commented Jul 14, 2015

👤 reinierz   🕗 Nov 02, 2009 at 00:12 UTC

v0.9.0 has been rolled out! Go ahead and tell maven to update your dependencies to v0.9.0.

@lombokissues

This comment has been minimized.

Show comment
Hide comment
@lombokissues

lombokissues Jul 14, 2015

Collaborator

End of migration

Collaborator

lombokissues commented Jul 14, 2015

End of migration

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment