typecheck failure on conversion of entity to enum
Think this is a bug.
I had an entity:
entity Day {
name :: String
}with some initialisation:
init {
/*
var day : Day;
day := Day { name := “Monday” };
day.save();
day := Day { name := “Tuesday” };
day.save();
//…
}Then converted the entity to an enum:
enum Day {
mon(“Monday”),
tue(“Tuesday”),
wed(“Wednesday”),
//…
}Kicked off a build, forgetting to remove corresponding code in the init function. All 9 webdsl stages ran successfully; error only surfaced during java compilation.
Shouldn’t there be a typecheck rule to catch this? Init code tries to create instance of enum - which I’d expect to be illegal.
Submitted on 1 April 2010 at 19:40
Log in to post comments