\r is accepted in unrestricted names and string literals without a nonstandard-notation warning, though KerML Table 4 does not list it (pilot grammar extension)
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 62/100
Research direction
Start from source.IsEscapeChar, which decides which escape sequences the lexer accepts, and from the nonstandard-notation check in internal/check/passes/nonstandard_notation.go. Keep \r decoding as it is, and make the existing warning fire for \r in both unrestricted names and string literals, escalating under -validate -strict. Done when the false-positive scan over examples/ and the standard library stays silent.
Written by the indexing model from the issue text.
Description
Model and observed behaviour
package P {
part def Pt;
part 'cr\rx' : Pt;
attribute s = "a\rb";
}
The model checks clean, under -validate -strict too: \r is accepted in an unrestricted name and in a string literal with no diagnostic, and is read as a carriage return (U+000D).
What the specification requires
KerML 1.1 Beta 2 §8.2.2.3, Note 2: "Table 4 shows the meaning of the allowed escape sequences." Table 4 (Escape Sequences) lists seven:
| Escape Sequence | Meaning |
|---|---|
\' |
Single Quote |
\" |
Double Quote |
\b |
Backspace |
\f |
Form Feed |
\t |
Tab |
\n |
Line Terminator |
\\ |
Backslash |
\r is not among them. §8.2.2.5 gives STRING_VALUE the same ESCAPE_SEQUENCE ("ESCAPE_SEQUENCE is specified in 8.2.2.3"), so the same holds for string literals.
Reference implementation
The pilot's grammar admits \r in both terminals (KerMLExpressions.xtext, pilot 2026-09):
terminal UNRESTRICTED_NAME returns Ecore::EString:
'\'' ('\\' ('b' | 't' | 'n' | 'f' | 'r' | '"' | "'" | '\\') | !('\\' | '\''))* '\'';
terminal STRING_VALUE returns Ecore::EString:
'"' ('\\' ('b' | 't' | 'n' | 'f' | 'r' | '"' | "'" | '\\') | !('\\' | '"'))* '"';
and its exporter gives declaredName cr + U+000D + x for the name above. source.IsEscapeChar follows that grammar.
Proposed
Keep accepting and decoding \r, so what the pilot accepts still parses, and report it through the existing nonstandard-notation warning (internal/check/passes/nonstandard_notation.go) — in an unrestricted name and in a string literal alike, with the strict-conformance escalation that warning already has. The same applies to any other sequence the lexer admits beyond Table 4; today \r is the only one.
No file under examples/ (the downloaded corpora included) or the standard library writes \r in a name or a string, so the warning should be silent over them; the false-positive scan should confirm that.
Split out of #2241 (which fixes #2214, the decoding of escape sequences in names) to keep that change to its scope.
Kind of gap
Accepted beyond the specification without a diagnostic
- Dominant language
- Go
- Stars
- 59
- Forks
- 20
- Avg merge
- 10h 23m
- Merged PRs (30d)
- 897
Getting set up
- Ships a Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Open-MBEE/OpenSysML
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 1 day
-
A model's parse is still paid cold in every process; the library record cache does not cover itOpen
Difficulty 5/5 Over a week Newbie friendliness 35/100
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 55/100
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 28/100
Maintainers usually reply within 1 day
All issues in Open-MBEE/OpenSysML
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
needs-triage
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
krakenhavoc/cmd_and_ctrl#5853 ·
Maintainers usually reply within 1 day
-
flaky test: TestTRTAsyncPrefillFailures/transport reads the token load before prefillDone has released itPossibly taken @Jackmeson1 claimed this today. Openarea/cicd area/gateway kind/misc
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
vllm-project/aibrix#3488 · 2 comments ·
Maintainers usually reply within 1 day
-
Type: Bug
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
projectdiscovery/httpx#2735 ·
Maintainers usually reply within 1 day
-
NuGet registry builds every URL from ROOT_URL, ignoring the host the client usedPossibly taken @gritse claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day