Skip to content

Instantly share code, notes, and snippets.

@savioserra
Created January 24, 2020 20:32
Show Gist options
  • Save savioserra/c22c7e3d03272b2ea8a55d789196d077 to your computer and use it in GitHub Desktop.
Save savioserra/c22c7e3d03272b2ea8a55d789196d077 to your computer and use it in GitHub Desktop.
class ConstExample {
final String someValue;
const ConstExample ({this.someValue});
}
void main() {
const d = ConstExample(someValue: "teste");
print(d.hashCode);
const e = ConstExample(someValue: "teste");
print(e.hashCode);
for (int i = 0; i < 5; i++) {
const v = ConstExample();
print(v.hashCode);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment