![]() |
Summary of stuff not working [V1.2.4] - Printable Version +- Forum (https://www.boriel.com/forum) +-- Forum: Compilers and Computer Languages (https://www.boriel.com/forum/forumdisplay.php?fid=12) +--- Forum: ZX Basic Compiler (https://www.boriel.com/forum/forumdisplay.php?fid=11) +---- Forum: Bug Reports (https://www.boriel.com/forum/forumdisplay.php?fid=15) +---- Thread: Summary of stuff not working [V1.2.4] (/showthread.php?tid=151) Pages:
1
2
|
Re: Summary of stuff not working [V1.24] - britlion - 02-12-2010 The comparisons all worked perfectly. Do tell - what was the bug? Was it just one? I can't seem to reproduce the CHR(var) problem right now. I DID have some issues that were cleared up by uninstalling and reinstalling at one point - it's possible some of the .py files got corrupted or something. I'm not quite sure what happened. So, as well as some real bugs, I may have had some other problems. I've updated the top post so anyone coming by can see what's happening. I hope it's clear! You haven't mentioned the tutorial stuff and the wiki updates on reserved words. Think that sort of thing is useful? I'm hoping so. The "faster code" thing was really some hints for people new to compiled spectrum basic. I could see some beginners needing some hand holding. I know we all hate to do documentation, so I'm trying to help out where I can. Right now the two issues I pointed out at the bottom to do with error messages are some of the biggest problems. It's very hard to track down where code is not correct because "unexpected end of file" doesn't give a clue where - and if you mistype a variable name, it can be very strange tracking down why it's not working! Re: Summary of stuff not working - LCD - 02-12-2010 britlion Wrote:Yeah, you've mentioned SVN. It's a tool I've heard about in coding circles once or twice, but never used. I'm not using the .zip version. I tried an msi install, and then thought I could use the .zip to upgrade...but apparently I can't. It has completely different files in it!You must install Python, and then call zxbc.py file to compile your program. I do use the msi version myself. Re: Summary of stuff not working [V1.24] - boriel - 02-12-2010 britlion Wrote:You haven't mentioned the tutorial stuff and the wiki updates on reserved words. Think that sort of thing is useful? I'm hoping so. The "faster code" thing was really some hints for people new to compiled spectrum basic. I could see some beginners needing some hand holding. I know we all hate to do documentation, so I'm trying to help out where I can.The wiki updates are great! Sorry I didn't mention it before (I think it should go in another thread). On the other hand, I was about to propose to include some of your code into the compiler (band, bor, bxor), because I was considering to put these as BASIC keywords: myVar band 0xFF and also myVar & 0xFF Yes (C-like operators too). So you can write &, |, ! or And/or/not. Unfortunately, bXor in C uses ^ char, which is power() operator in ZX Spectrum BASIC so we sould consider another symbol. Re: Summary of stuff not working [V1.24] - britlion - 02-12-2010 I cheated quite a bit with the binary functions (using fastcall as a 16 bit). I think I may have a handle on how stdCall works, but it would be nice to know what is on the stack when a call to a function happens. There's quite a lot on the stack, and it seems to be replicated with the registers (that is, for something like LONG,LONG - DEHL has the first one, and the stack has both.) There's also some number on the stack ahead of the return address and I can't work out what it's for. As for Xor - I'm not sure what to shortcut for that. Obviously bXor is the way to go in text. We could totally confuse people and use % so they think it's MOD There aren't many left that wouldn't be confusing. ! is factorial, ? is usually used as a ternary if/then/else (or even a synonym for print, which I never understood). You've used @ as a pointer for the memory address, and # is tied up with the preprocessor - unless it can do double duty. ~ ? ![]() How good is the compiler at not including runtimes it doesn't need at the moment? Re: Summary of stuff not working [V1.24] - LCD - 02-13-2010 britlion Wrote:~ ?I'm supporting this. In PureBasic this is also used for BXOR. Re: Summary of stuff not working [V1.24] - boriel - 02-21-2010 LCD Wrote:britlion Wrote:~ ?I'm supporting this. In PureBasic this is also used for BXOR. Ok, I agree. ~ symbol will be used as an alias for BXOR. Re: Summary of stuff not working [V1.24] - britlion - 02-24-2010 New bug! LCD reported SHL and SHR as failing for Integer types. It works for byte, uByte, long and uLong. Code: CLS This will not compile if you put <type> as uInteger or Integer. Re: Summary of stuff not working [V1.24] - boriel - 02-24-2010 britlion Wrote:New bug!I've already fixed if (15 min ago! :lol: ) Read here <!-- l --><a class="postlink-local" href="http://www.boriel.com/forum/viewtopic.php?f=14&t=388#p868">viewtopic.php?f=14&t=388#p868</a><!-- l --> ![]() Re: Summary of stuff not working [V1.24] - britlion - 02-24-2010 boriel Wrote: Agreed! Let's CLOSE this thread then. Re: Summary of stuff not working [V1.24] - boriel - 03-05-2010 The CHR$ crashes and memory corruption are probably related to the memory corruption bug recently fixed: memory corruption affected strings (INKEY$, CHR$). I'm sure this explains the strange CHR$ behavior you experimented before and why you can't reproduce it now. |