Skip to content

Commit

Permalink
fix compile errors
Browse files Browse the repository at this point in the history
  • Loading branch information
RetroDev256 committed Sep 24, 2024
1 parent 56b7655 commit 67e31c5
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lib/compiler/aro/aro/Preprocessor.zig
Original file line number Diff line number Diff line change
Expand Up @@ -1745,7 +1745,7 @@ fn expandFuncMacro(
}
if (!pp.comp.langopts.standard.atLeast(.c23)) break :res not_found;

const attrs = std.StaticStringMap([]const u8).initComptime(.{
const attrs = comptime std.StaticStringMap([]const u8).initComptime(.{
.{ "deprecated", "201904L\n" },
.{ "fallthrough", "201904L\n" },
.{ "maybe_unused", "201904L\n" },
Expand Down
2 changes: 1 addition & 1 deletion lib/std/http/Client.zig
Original file line number Diff line number Diff line change
Expand Up @@ -1570,7 +1570,7 @@ pub const RequestOptions = struct {
};

fn validateUri(uri: Uri, arena: Allocator) !struct { Connection.Protocol, Uri } {
const protocol_map = std.StaticStringMap(Connection.Protocol).initComptime(.{
const protocol_map = comptime std.StaticStringMap(Connection.Protocol).initComptime(.{
.{ "http", .plain },
.{ "ws", .plain },
.{ "https", .tls },
Expand Down
4 changes: 2 additions & 2 deletions lib/std/static_string_map.zig
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ pub fn StaticStringMapAdvanced(
const testing = std.testing;

test "comptime only value" {
const map = StaticStringMap(type).initComptime(.{
const map = comptime StaticStringMap(type).initComptime(.{
.{ "a", struct {
pub const foo = 1;
} },
Expand All @@ -183,7 +183,7 @@ test "comptime only value" {
}

test "get/has with edge cases" {
const map = StaticStringMap(u32).initComptime(&.{
const map = comptime StaticStringMap(u32).initComptime(&.{
.{ "a", 0 },
.{ "ab", 3 },
.{ "abc", 0 },
Expand Down

0 comments on commit 67e31c5

Please sign in to comment.