Christoffer Lerno
Christoffer Lerno
I remember, I was investigating this and found that it was more or less deliberate and it's desirable to fix corner cases (and this possibly means that other `..` should...
For example `c[0..-1]` should probably work.
I've relaxed the rules so that all of these are now allowed by default.
I don't pass those arguments to LLVM, so it's likely that they form some kind of default? What does Clang output?
And Zig did not have these either? I see that Zig explicitly adds those to the functions. Can you perhaps run emcc and output some LLVM for the same example...
It looks like if mutable-globals and sign-ext isn't added to all functions it's added during linking then?
Hmm.. what would be the use of this? Given that this works it will still just print 42.
Maybe you're thinking of a name lookup? In that case it would be more like: ```c fn void main() { Foo f = (Foo)42; String name = f.lookup_name(); io::printfn("Value: %s",...
That one seems correct, although you can write it more succinctly as: ```c fn String Foo.get_name(&self) { foreach (i, &val : Foo.values) { if (*self == *val) { return Foo.names[i];...