Including C code cache problem? #22157
Unanswered
jorgeluismireles
asked this question in
Questions and Answers
Replies: 1 comment
-
By the way, the folder https://github.com/vlang/v/tree/master/vlib/v/tests contains according to github more than 1000 entries, and not all are displayed by github and then we loose the chance to navigate there to look for more examples to try. Maybe making sub-folders can permit to see everything from github. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I follow the https://docs.vlang.io/v-and-c.html#including-c-code doc to compile a c file I have. Then I had problems so copy, paste and update the code at https://github.com/vlang/v/tree/master/vlib/v/tests/project_with_c_code.
First I though was mandatory to have the C folder named exactly
c
and the c code as exactlyimplementation.c
but I wasn't the case.Then notice like a cache is causing problems, since I modifed the
.c
file to get an expected assert error but the program run correctly as if the file wasn't touched. Even I changed the name of the file in order to cannot be found but no error was indicated for the newv run
. These problems difficult the edition process.Also something strange happens when I make a typo in the line
#flag @VMODROOT/mod1/code/libx.o
and I got this:Seems the compiler thinks we want to compile a c++ file.
Ideas? V 0.4.7 da228e9
Beta Was this translation helpful? Give feedback.
All reactions