mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
Added new style named arguments.
This commit is contained in:
@@ -105,7 +105,7 @@ fn Path! new_get_config_dir(Allocator allocator = allocator::heap())
|
||||
String s = get_var_temp("XDG_CONFIG_HOME") ?? get_var_temp("HOME")!;
|
||||
const DIR = ".config";
|
||||
$endif
|
||||
return path::temp_new(s).new_append(DIR, .allocator = allocator);
|
||||
return path::temp_new(s).new_append(DIR, allocator: allocator);
|
||||
$endif
|
||||
};
|
||||
}
|
||||
|
||||
@@ -193,10 +193,10 @@ fn Backtrace! resolve_backtrace(void* addr, Win32_HANDLE process, Allocator allo
|
||||
ZString zname = (ZString)&name;
|
||||
if (!symGetLineFromAddr64(process, (Win32_ULONG64)addr - 1, &offset, &line))
|
||||
{
|
||||
backtrace.init((uptr)addr, zname.str_view(), module_name.str_view(), .allocator = allocator);
|
||||
backtrace.init((uptr)addr, zname.str_view(), module_name.str_view(), allocator: allocator);
|
||||
return backtrace;
|
||||
}
|
||||
String filename = ((ZString)line.fileName).str_view();
|
||||
backtrace.init((uptr)addr, zname.str_view(), module_name.str_view(), .file = filename, .line = line.lineNumber, .allocator = allocator);
|
||||
backtrace.init((uptr)addr, zname.str_view(), module_name.str_view(), file: filename, line: line.lineNumber, allocator: allocator);
|
||||
return backtrace;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user