Skip to content

Latest commit

 

History

History
45 lines (33 loc) · 723 Bytes

File metadata and controls

45 lines (33 loc) · 723 Bytes

UEA0008: UnsealedDerivedClass

Property Value
Id UEA0008
Category Performance
Severity Warning

Example

Code with Diagnostic

using UnityEngine;

public abstract class Animal {
  public abstract string Speak();
}
 
public class Cow : Animal {
   public override string Speak() {
       return "Moo";
   }
}

Code with Fix

using UnityEngine;

public abstract class Animal {
  public abstract string Speak();
}
 
public sealed class Cow : Animal {
   public override string Speak() {
       return "Moo";
   }
}

See also

https://blogs.unity3d.com/2016/07/26/il2cpp-optimizations-devirtualization/