hat
hat
MModular
Created by hat on 3/30/2024 in #questions
What does the asterisk in this mojo code mean? fn __init__(inout self, *, capacity: Int):
I'm curious about the source code for List (https://github.com/modularml/mojo/blob/main/stdlib/src/collections/list.mojo#L105C5-L105C47), which has this line
fn __init__(inout self, *, capacity: Int):
...
fn __init__(inout self, *, capacity: Int):
...
What does the asterisk * mean in the function's parameters?
3 replies
MModular
Created by hat on 2/7/2024 in #questions
`atof` in Mojo?
Does Mojo currently have a function to convert real numbers represented by strings to Float64's? Something like C's atof function?
2 replies