We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
interface
The keyword interface is not being renamed, causing invalid code to be translated. Given the code below:
#include <stdio.h> void print_interface(int interface) { printf("%d\n", interface); } int main() { print_interface(100); return 0; }
c2v outputs:
❯ v translate test.c C to V translator 0.4.1 translating /home/dylan/test.c ... #include <stdio.h> void print_interface(int interface) { printf("%d\n", interface); } int main() { print_interface(100); return 0; } path=/home/dylan/test.c main loop 2 1FN DECL c_name="print_interface" cur_file="/home/dylan/test.c" node.location.file="/home/dylan/test.c" 1FN DECL c_name="main" cur_file="/home/dylan/test.c" node.location.file="" test.v:5:20: error: invalid expression: unexpected keyword `interface` 3 | 4 | fn print_interface(interface int) { 5 | C.printf(c'%d\n', interface) | ~~~~~~~~~ 6 | } 7 | Internal vfmt error while formatting file: /home/dylan/test.v. c2v translate_file() took 37 ms ; output .v file: test.v Translated 1 files in 37 ms.
The below file is generated, which will not run:
@[translated] module main fn print_interface(interface int) { C.printf(c'%d\n', interface) } fn main() { print_interface(100) return }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
The keyword
interface
is not being renamed, causing invalid code to be translated.Given the code below:
c2v outputs:
The below file is generated, which will not run:
The text was updated successfully, but these errors were encountered: