Gamestudio Links
Zorro Links
Newest Posts
Data from CSV not parsed correctly
by EternallyCurious. 04/18/24 10:45
StartWeek not working as it should
by Zheka. 04/18/24 10:11
folder management functions
by VoroneTZ. 04/17/24 06:52
lookback setting performance issue
by 7th_zorro. 04/16/24 03:08
zorro 64bit command line support
by 7th_zorro. 04/15/24 09:36
Zorro FIX plugin - Experimental
by flink. 04/14/24 07:48
Zorro FIX plugin - Experimental
by flink. 04/14/24 07:46
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (AndrewAMD), 677 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
EternallyCurious, howardR, 11honza11, ccorrea, sakolin
19047 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 2 of 2 1 2
Re: lite-C bug [Re: AndrewAMD] #467861
09/04/17 18:51
09/04/17 18:51
Joined: Aug 2017
Posts: 58
P
pascalx Offline OP
Junior Member
pascalx  Offline OP
Junior Member
P

Joined: Aug 2017
Posts: 58
Originally Posted By: AndrewAMD
Welcome to Lite C!!! grin


http://www.zorro-trader.com/manual/en/cscript_intro.htm

Quote:
The disadvantage of a script is obviously that you have to learn the script language. Most products using strategy scripts require that you dive deeply into programming. No so with Zorro: lite-C is arguably the world's easiest serious programming language. It 'hides' almost all the programming stuff and allows you to concentrate on plain strategy. You can learn the lite-C essentials in about one day.


I think the emphasis here is on "arguably" grin

I don't understand how offering a limited subset of features is better than offering the whole package.
I rather take the whole thing even if I don't need all of it.
But it's ok. The upcoming Zorro DLL will solve a lot of headache.

Last edited by pascalx; 09/04/17 18:55.
Re: lite-C bug [Re: pascalx] #467863
09/04/17 19:33
09/04/17 19:33
Joined: Apr 2007
Posts: 3,751
Canada
WretchedSid Offline
Expert
WretchedSid  Offline
Expert

Joined: Apr 2007
Posts: 3,751
Canada
Because a broken subset of C is much easier to implement as a compiler. Why not use a LLVM/Clang as a compiler backend? Because they didn't exist back in 1423 when Lite-C was invented. But really, it's because with LLVM/Clang we would have never had the drama of the Chinese freelancer that bailed halfway through implementing the compiler leaving JCL with a bunch of Chinese comments and a voodoo black magic compiler.


Shitlord by trade and passion. Graphics programmer at Laminar Research.
I write blog posts at feresignum.com
Re: lite-C bug [Re: WretchedSid] #467864
09/04/17 19:57
09/04/17 19:57
Joined: Aug 2017
Posts: 58
P
pascalx Offline OP
Junior Member
pascalx  Offline OP
Junior Member
P

Joined: Aug 2017
Posts: 58
Originally Posted By: WretchedSid
1423



Re: lite-C bug [Re: pascalx] #468175
09/22/17 11:35
09/22/17 11:35
Joined: Jun 2007
Posts: 1,337
Hiporope and its pain
txesmi Offline
Serious User
txesmi  Offline
Serious User

Joined: Jun 2007
Posts: 1,337
Hiporope and its pain
Code:
int *_ap = &1;
*_ap += 1;
error ( str_for_int ( NULL, 1 ) ); // Prints 2


Re: lite-C bug [Re: txesmi] #468745
10/15/17 13:20
10/15/17 13:20
Joined: Aug 2017
Posts: 58
P
pascalx Offline OP
Junior Member
pascalx  Offline OP
Junior Member
P

Joined: Aug 2017
Posts: 58
Wait - every one is a two then? Hahaha.

Re: lite-C bug [Re: pascalx] #468746
10/15/17 15:35
10/15/17 15:35
Joined: Oct 2011
Posts: 1,082
Germany
C
Ch40zzC0d3r Offline
Serious User
Ch40zzC0d3r  Offline
Serious User
C

Joined: Oct 2011
Posts: 1,082
Germany
They probably have all constants in the data section, therefore this is possible on this compiler lol.
Take a look at the generated assembly.

Last edited by Ch40zzC0d3r; 10/15/17 15:36.
Re: lite-C bug [Re: Ch40zzC0d3r] #468747
10/15/17 16:00
10/15/17 16:00
Joined: Nov 2007
Posts: 2,568
Germany, BW, Stuttgart
MasterQ32 Offline
Expert
MasterQ32  Offline
Expert

Joined: Nov 2007
Posts: 2,568
Germany, BW, Stuttgart
you can also write any statements outside of function definitions:

Code:
#include <acknex.h>

int i, j, k;
i = 10;
j = 20;
k = i + j;

printf("i=%d", i);

function main()
{

}



Nothing will happen, the compiler won't even emit a warning

Fun Fact:
You can implement generic functions with the behaviour that you can take the address of a constant:

Code:
void _list_add(void * list, void * obj, int size);

#define list_add(list, obj) _list_add(list, &obj, sizeof(obj))

...

list_add(myList, 10);
list_add(myList, 20);



Visit my site: www.masterq32.de
Page 2 of 2 1 2

Moderated by  Petra 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1