Skip to content

Commit

Permalink
fix: Make CtField inherit from CtResource
Browse files Browse the repository at this point in the history
Fields are allowed in try-with-resources statements now, so spoon should
model this case.
  • Loading branch information
I-Al-Istannen committed Jun 18, 2024
1 parent c7b41ca commit e454633
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/main/java/spoon/reflect/declaration/CtField.java
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,15 @@

import spoon.reflect.code.CtExpression;
import spoon.reflect.code.CtRHSReceiver;
import spoon.reflect.code.CtResource;
import spoon.reflect.reference.CtFieldReference;
import spoon.support.DerivedProperty;
import spoon.support.UnsettableProperty;

/**
* This element defines a field declaration.
*/
public interface CtField<T> extends CtVariable<T>, CtTypeMember, CtRHSReceiver<T>, CtShadowable {
public interface CtField<T> extends CtVariable<T>, CtResource<T>, CtTypeMember, CtRHSReceiver<T>, CtShadowable {

/**
* The separator for a string representation of a field.
Expand Down

0 comments on commit e454633

Please sign in to comment.