Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion build.zig.zon
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
// nix flake update --commit-lock-file
// ```
// If you do not use Nix, a ZLS maintainer can take care of this.
.minimum_zig_version = "0.18.0-dev.897+117fd40fb",
.minimum_zig_version = "0.18.0-dev.1005+75d48dfff",
// Must be kept in sync with the `deps.nix` for the Nix flake.
// If you do not use Nix, a ZLS maintainer can take care of this.
.dependencies = .{
Expand Down
12 changes: 6 additions & 6 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions src/DocumentScope.zig
Original file line number Diff line number Diff line change
Expand Up @@ -241,11 +241,11 @@ pub const Scope = struct {
}
};

pub const Data = packed union {
pub const Data = bitpack union {
ast_node: Ast.Node.Index,
};

pub const SmallLoc = packed struct {
pub const SmallLoc = bitpack struct {
start: u32,
end: u32,
};
Expand All @@ -270,7 +270,7 @@ pub const Scope = struct {
},
};

data: packed struct(u64) {
data: bitpack struct(u64) {
tag: Tag,
is_child_scopes_small: bool,
is_child_decls_small: bool,
Expand Down
2 changes: 1 addition & 1 deletion src/TrigramStore.zig
Original file line number Diff line number Diff line change
Expand Up @@ -517,7 +517,7 @@ const CuckooFilter = struct {
index_2: BucketIndex,

pub fn initFromTrigram(trigram: Trigram, len: u32) Triplet {
const split: packed struct {
const split: bitpack struct {
fingerprint: Fingerprint,
padding: u24,
index_1: u32,
Expand Down
16 changes: 8 additions & 8 deletions src/analyser/InternPool.zig
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ pub const Key = union(enum) {
flags: Flags,
packed_offset: PackedOffset = .{ .bit_offset = 0, .host_size = 0 },

pub const Flags = packed struct(u32) {
pub const Flags = bitpack struct(u32) {
size: std.lang.Type.Pointer.Size,
is_const: bool = false,
is_volatile: bool = false,
Expand All @@ -84,7 +84,7 @@ pub const Key = union(enum) {
alignment: u16 = 0,
};

pub const PackedOffset = packed struct(u32) {
pub const PackedOffset = bitpack struct(u32) {
bit_offset: u16,
host_size: u16,
};
Expand Down Expand Up @@ -123,7 +123,7 @@ pub const Key = union(enum) {
return_type: Index,
flags: Flags = .{},

pub const Flags = packed struct(u32) {
pub const Flags = bitpack struct(u32) {
calling_convention: std.lang.CallingConvention.Tag = .auto,
is_generic: bool = false,
is_var_args: bool = false,
Expand Down Expand Up @@ -197,7 +197,7 @@ pub const Key = union(enum) {
}
};

const F64Value = packed struct {
const F64Value = bitpack struct {
a: u32,
b: u32,

Expand All @@ -210,7 +210,7 @@ pub const Key = union(enum) {
}
};

const F80Value = packed struct {
const F80Value = bitpack struct {
a: u32,
b: u32,
c: u32,
Expand All @@ -226,7 +226,7 @@ pub const Key = union(enum) {
}
};

const F128Value = packed struct {
const F128Value = bitpack struct {
a: u32,
b: u32,
c: u32,
Expand Down Expand Up @@ -3307,7 +3307,7 @@ pub fn isUnsignedInt(ip: *InternPool, ty: Index, target: std.Target) bool {
};
}

/// Asserts the type is an integer, enum, error set, packed struct, or vector of one of them.
/// Asserts the type is an integer, enum, error set, bitpack struct, or vector of one of them.
pub fn intInfo(ip: *InternPool, ty: Index, target: std.Target) std.lang.Type.Int {
var index = ty;
while (true) switch (index) {
Expand Down Expand Up @@ -3349,7 +3349,7 @@ pub fn intInfo(ip: *InternPool, ty: Index, target: std.Target) std.lang.Type.Int
},
.struct_type => |struct_index| {
const struct_info = ip.getStruct(struct_index);
assert(struct_info.layout == .@"packed");
assert(struct_info.layout == .@"bitpack");
index = struct_info.backing_int_ty;
},
// TODO revisit this when error sets support custom int types (comment taken from zig codebase)
Expand Down
4 changes: 2 additions & 2 deletions src/configuration.zig
Original file line number Diff line number Diff line change
Expand Up @@ -638,9 +638,9 @@ pub const UnresolvedConfig = blk: {
break :blk @Struct(.auto, null, struct_info.field_names, &field_types, &field_attrs);
};

/// A packed struct where every field name is copied from `Config` but the field type is `bool`.
/// A bitpack struct where every field name is copied from `Config` but the field type is `bool`.
pub const DidConfigChange = @Struct(
.@"packed",
.@"bitpack",
null,
@typeInfo(Config).@"struct".field_names,
&@splat(bool),
Expand Down
2 changes: 1 addition & 1 deletion src/features/semantic_tokens.zig
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ pub const TokenType = enum(u32) {
keywordLiteral,
};

pub const TokenModifiers = packed struct(u16) {
pub const TokenModifiers = bitpack struct(u16) {
declaration: bool = false,
definition: bool = false,
readonly: bool = false,
Expand Down
Loading
Loading