You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is (maybe!) more about text rather than something visual.
In programming we have metrics like "line length" or "function lines count" or "cyclomatic complexity" (count of nested ifs and fors`) which is great but can we do better?
What about "readability Quantum"? Take a look at this example
do(x.y[0].z())
Theres 5 expressions there:
do()
x.
y[0]
.z
z()
By defining quantum as simply expression we got 5 quanta. Question is - is this definition good enough for FBP language like Neva? We don't really have "expressions" in a program structure, even though we can have them in textual (expression-based) representation like the ones we discuss in #65 and #101.
Now personally I find 5 quanta per line pretty bad metric value but that's out of the scope. We can probably configure linters (BTW check #122) anyway we want to catch such a things. Next question is will "per line" also work pretty well. Line is not a program entity in contrast with things like "functions" or "components". They only make sense for specific textual representation in case of Neva that can have (in theory) many different front-ends. Maybe better separators would be "per network", "per nodes", "per port definition", etc.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
This is (maybe!) more about text rather than something visual.
In programming we have metrics like "line length" or "function lines count" or "cyclomatic complexity" (count of nested
if
s andfor
s`) which is great but can we do better?What about "readability Quantum"? Take a look at this example
Theres 5 expressions there:
do()
x.
y[0]
.z
z()
By defining quantum as simply expression we got 5 quanta. Question is - is this definition good enough for FBP language like Neva? We don't really have "expressions" in a program structure, even though we can have them in textual (expression-based) representation like the ones we discuss in #65 and #101.
Now personally I find 5 quanta per line pretty bad metric value but that's out of the scope. We can probably configure linters (BTW check #122) anyway we want to catch such a things. Next question is will "per line" also work pretty well. Line is not a program entity in contrast with things like "functions" or "components". They only make sense for specific textual representation in case of Neva that can have (in theory) many different front-ends. Maybe better separators would be "per network", "per nodes", "per port definition", etc.
Beta Was this translation helpful? Give feedback.
All reactions