Commit 6993b006 authored by Markus Klinik's avatar Markus Klinik
Browse files

simplify

parent b09140ef
......@@ -17,6 +17,7 @@ set[Message] allCodingRules(M3 model)
+ ps_dedicated_main(model)
+ ps_explicit_access_modifiers(model)
+ ps_public_attributes(model)
+ ps_one_constructor_minimum(model)
;
// Given an M3 model, returns all classes whose name does not start with an uppercase letter
......@@ -83,12 +84,14 @@ set[Message] ps_explicit_access_modifiers(M3 model)
// If an attribute is public, it must be final
set[Message] ps_public_attributes(M3 model)
{
set[Message] result =
set[Message] ps_public_attributes(M3 model) =
{ error("Only final attributes may be public", field)
| field <- range(declaredFields(model))
, \public() in model.modifiers[field] && !(\final() in model.modifiers[field])
};
return result;
set[Message] ps_one_constructor_minimum(M3 model)
{
}
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment