10 Commits

Author SHA1 Message Date
Zeex
c20d9cb33b Fix compile crash when calling a function at global scope
This fixes a crash that occurs if a global variable is initialized
with the result of a function call.

See 3) here: http://forum.sa-mp.com/showthread.php?t=355877

--------- test code --------

native use(...);

f() {
	return 0;
}

new x = f();

main() {
	use(x);
}

----- end of test code -----
2014-01-01 16:49:55 +07:00
Zeex
0c8f23453e Fix compile error with string literals in ternary operator
The ':' symbol was not recognized as a separator in stringize mode
so you always got a weird compile error with a code like this:

(condition) ? "yes : "no"

error 001: expected token: "-string end-", but found "-identifier-"

See 2) here: http://forum.sa-mp.com/showthread.php?t=355877

Test code:

native print(const s[]);

main() {
	new a = 5;
	print((a == 5) ? "is five" : !"is not five");
	print((a != 5) ? !"is not five" : "is five");
}
2014-01-01 03:49:30 +07:00
Zeex
4831cb76a3 Different fix for arrays of unpacked strings
Do it the same way as it's done for packed strings, for consistency.
2013-12-31 01:38:45 +07:00
Zeex
c316b6d3be Fix CMake warnings 2013-12-27 18:52:21 +07:00
Zeex
d9999d4da8 Fix compile error with arrays of packed strings
This fixes the "possibly non-terminated string" error when declaring an
array of packed strings (unpacked strings worked OK).

Test code:

new x[][] = {
	!"hello",
	!"world"
};

main() {
	printf("%s", x[0]);
}
2013-12-27 02:41:37 +07:00
Zeex
99df013361 Add pawn-lang.pdf 2013-10-07 23:09:17 +07:00
Zeex
be9842f5a2 Add pawn-imp.pdf 2013-10-07 22:47:41 +07:00
Zeex
79f2031cab Revert breaking changes
It looks like I accidentally applied not_samp_compatible patches before
uploading the code.
2013-09-22 22:06:20 +07:00
Zeex
766b96bcf3 Lower case directory names 2013-09-19 13:06:46 +07:00
Zeex
00f21e67d5 Pawn 3.2.3664 code with samp_compatible patches applied 2013-05-09 01:32:43 +07:00