Alexander Medvednikov
f5c8ee4742
string(buffer, len) cast
2019-07-18 04:50:44 +02:00
d2verb
92fbe56276
table: fix #1219
2019-07-18 04:32:49 +02:00
Alexander Medvednikov
c35adbea91
vfmt fixes
2019-07-17 21:00:39 +02:00
Alexander Medvednikov
7dc7502fe2
fix REPL and hot code reloading for users that don't have V in PATH
2019-07-17 19:23:47 +02:00
Alexander Medvednikov
b9f3f2d622
v script
2019-07-17 13:49:42 +02:00
Alexander Medvednikov
14ad70d3a0
match: else
2019-07-17 02:47:45 +02:00
Alexander Medvednikov
76d6e9fd1a
minor match_test.v fixes
2019-07-17 02:44:41 +02:00
Alexander Medvednikov
a9463a180d
new match statement
2019-07-17 02:41:08 +02:00
Igor Pershikov
3f506714ec
Fix bug with BOM
2019-07-17 00:05:04 +02:00
Delyan Angelov
5d0cb1437c
Add support for VFLAGS environment variable, merged with cmd args.
...
Using VFLAGS, you can pass common options through it to the V compiler,
without having to manually specify them everytime when you type V ...
In addition, since environment variables are *inherited*, all subprocess
V compilers, which V launches (for example when compiling with -live),
will *also* use the same VFLAGS environment variable.
Example usage:
export VFLAGS="-debug -show_c_cmd"
v -live message.v
=> This will keep *both* of the generated C source files .message.c
*AND* .message_shared_lib.c . It will also cause both V compile
subprocesses to print their resulting C compiler backend lines.
This is very useful when using GDB to debug problems.
2019-07-16 19:35:16 +02:00
Delyan Angelov
17580f3013
Support for passing different options to the C compiler backend.
...
Example: 'v -c_options=-Os' will pass -Os to the C compiler.
In effect the C compiler will optimize the generated binary for size.
2019-07-16 19:34:44 +02:00
Alexander Medvednikov
1748632144
do not create ~/.vlang directory
2019-07-16 17:44:25 +02:00
Alexander Medvednikov
8aa7da1be1
http_win: fix BUF_MAX
2019-07-16 15:29:27 +02:00
Alexander Medvednikov
54b069f9ad
fix high order fns
2019-07-16 14:39:34 +02:00
Alexander Medvednikov
8c516bec4f
[][]int
2019-07-16 13:56:48 +02:00
Alexander Medvednikov
31032d3a62
allow field 'type'
2019-07-16 13:01:39 +02:00
Alexander Medvednikov
830f63e86a
make maps work with structs defined in different modules
2019-07-16 12:18:52 +02:00
Alexander Medvednikov
0a4a9a35c3
.key_type
2019-07-16 12:17:17 +02:00
Alexander Medvednikov
eb7aee5ae0
store temp C files in the same directory
2019-07-16 02:12:05 +02:00
Alexander Medvednikov
cc06fe7ae6
os.dir(); fix vroot on Windows
2019-07-16 01:57:06 +02:00
Alexander Medvednikov
8902256592
V 0.1.15
2019-07-15 23:56:18 +02:00
Alexander Medvednikov
edbcefb811
fix and simplify VROOT
2019-07-15 23:33:31 +02:00
Alexander Medvednikov
840e496a51
force snake_case in variable names
2019-07-15 22:53:33 +02:00
Alexander Medvednikov
100bcc2034
use defer
2019-07-15 22:18:43 +02:00
Alexander Medvednikov
17c6ba04a2
defer statement
2019-07-15 22:13:12 +02:00
Alexander Medvednikov
62e6e03492
-ldl is only required on Linux
2019-07-15 20:40:37 +02:00
Alexander Medvednikov
9b020fad53
fix OpenBSD build
2019-07-15 20:22:48 +02:00
Alexander Medvednikov
374781da1a
OpenBSD, NetBSD, DragonFly support
2019-07-15 20:19:07 +02:00
Alexander Medvednikov
449fd372f9
*_nix.v support
2019-07-15 19:23:09 +02:00
Alexander Medvednikov
b36a9f7e55
glfw always on top
2019-07-15 19:23:09 +02:00
Delyan Angelov
37aff9b107
hot reload: no -sanitize is needed anymore, -live is now enough on both Linux and MacOS X
...
* hot reload for GL programs: force the main executable (the shared library loader) to be build with -rdynamic flag, when -live is passed to v compiler.
* hot reload: optimize away a redundant load_so/0 call at the start of the reload_so thread.
* hot code reload for MacOSX requires -flat_namespace flag instead of -rdynamic (on linux).
2019-07-15 17:32:00 +02:00
Alexander Medvednikov
7c6f59afa6
FreeBSD support
2019-07-15 17:24:44 +02:00
d2verb
4020a3ab8c
Prevent main function form returning value
2019-07-15 17:19:24 +02:00
d2verb
40ad868f22
Fix #1107
2019-07-15 16:30:06 +02:00
Henrixounez
48c06df5f5
parser: fix bug not printing percentages
2019-07-15 14:26:39 +02:00
d2verb
916b13b286
fix maps
2019-07-15 12:33:18 +02:00
Delyan Angelov
0556f5fd4e
When compiling with -shared (a step in compiling with -live), store the C intermediary file in a different file than main (loader) file, so that debugging symbol lookup information is correct (the files are not replaced constantly with each other).
2019-07-15 12:30:03 +02:00
Delyan Angelov
60ad97c4fb
fix hot code reloading for GUI example bounce on linux: works when compiled with 'v -live -sanitize bounce.v' .
...
It crashes with SIGSEGV, when -sanitize is not given.
Also thirdparty/glad/glad.o should be build with -fPIC .
2019-07-15 12:28:35 +02:00
Alexander Medvednikov
f7dbbf5810
re-write map.v and update the compiler
2019-07-14 22:08:17 +02:00
hazohelet
441281dd4f
parser: fix small typo
2019-07-14 16:48:57 +02:00
Alexander Medvednikov
48f841bb26
make enums defined in other modules work
2019-07-14 00:10:53 +02:00
joe-conigliaro
b4afa964fc
hash/crc32
2019-07-13 15:11:32 +02:00
Nick Treleaven
cec3ea5b4d
Document v -lib
and don't advertise --help
long option
...
--help and --version are accepted, but these don't fit the `-option`
format of V's other options. To avoid confusion, don't mention them.
2019-07-13 14:54:31 +02:00
d2verb
2811145437
Add enum_test.v
2019-07-13 12:19:57 +02:00
joe-conigliaro
298ca8676f
Change import syntax to "import as alias"
2019-07-13 12:15:16 +02:00
aguspiza
d0e7d0070d
fix travis windows user home
2019-07-12 20:35:01 +02:00
hazohelet
2a0d8072c1
delete unnecessary lines
2019-07-12 15:46:15 +02:00
joe-conigliaro
9a957ccc18
module aliasing & file import scope
2019-07-12 07:37:54 +02:00
Alexander Medvednikov
56b7c9e35f
for key, val in map syntax
2019-07-12 07:27:30 +02:00
hazohelet
b039538a27
parser: fix if expressions with multiple else if's
2019-07-12 06:54:01 +02:00