mirror of
https://codeberg.org/ziglang/zig.git
synced 2025-12-06 13:54:21 +00:00
remove extra space in .** error message
This commit is contained in:
parent
e59f44712d
commit
bb6e39e274
3 changed files with 3 additions and 3 deletions
|
|
@ -326,7 +326,7 @@ pub const Error = union(enum) {
|
||||||
pub const ExtraAllowZeroQualifier = SimpleError("Extra allowzero qualifier");
|
pub const ExtraAllowZeroQualifier = SimpleError("Extra allowzero qualifier");
|
||||||
pub const DeclBetweenFields = SimpleError("Declarations are not allowed between container fields");
|
pub const DeclBetweenFields = SimpleError("Declarations are not allowed between container fields");
|
||||||
pub const InvalidAnd = SimpleError("`&&` is invalid. Note that `and` is boolean AND.");
|
pub const InvalidAnd = SimpleError("`&&` is invalid. Note that `and` is boolean AND.");
|
||||||
pub const AsteriskAfterPointerDereference = SimpleError("`.*` can't be followed by `*`. Are you missing a space?");
|
pub const AsteriskAfterPointerDereference = SimpleError("`.*` can't be followed by `*`. Are you missing a space?");
|
||||||
|
|
||||||
pub const ExpectedCall = struct {
|
pub const ExpectedCall = struct {
|
||||||
node: *Node,
|
node: *Node,
|
||||||
|
|
|
||||||
|
|
@ -594,7 +594,7 @@ void tokenize(Buf *buf, Tokenization *out) {
|
||||||
case TokenizeStateSawDotStar:
|
case TokenizeStateSawDotStar:
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case '*':
|
case '*':
|
||||||
tokenize_error(&t, "`.*` can't be followed by `*`. Are you missing a space?");
|
tokenize_error(&t, "`.*` can't be followed by `*`. Are you missing a space?");
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
t.pos -= 1;
|
t.pos -= 1;
|
||||||
|
|
|
||||||
|
|
@ -8216,6 +8216,6 @@ pub fn addCases(cases: *tests.CompileErrorContext) void {
|
||||||
\\ var sequence = "repeat".*** 10;
|
\\ var sequence = "repeat".*** 10;
|
||||||
\\}
|
\\}
|
||||||
, &[_][]const u8{
|
, &[_][]const u8{
|
||||||
"tmp.zig:2:30: error: `.*` can't be followed by `*`. Are you missing a space?",
|
"tmp.zig:2:30: error: `.*` can't be followed by `*`. Are you missing a space?",
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue