klyn.code.LanguageProfile.isComplexityKeyword
method
public isComplexityKeyword(word as String) as Boolean
Description

Checks in $O(1)$ whether word is a cyclomatic complexity decision token.

Parameters
ParameterDescription
wordToken text to test.
Returns

true if word increases cyclomatic complexity.

Example
import klyn.code

p = LanguageProfile("klyn", "Klyn").withComplexityKeywords(["if", "while"])
assert p.isComplexityKeyword("if")