Commit Graph

4213 Commits

Author SHA1 Message Date
Colin Leroy-Mira
8a793796d7 Coding style 2025-07-20 16:14:35 +02:00
Colin Leroy-Mira
8ba1cef550 Merge branch 'master' into Opt-ldptr1 2025-07-20 16:08:01 +02:00
Colin Leroy-Mira
17b8645360 Optimize ldax?sp/sta/stx to ldptr1?sp 2025-07-20 12:24:24 +02:00
Jimmy Dansbo
3cd1672ae5 Added correct capabilities to W65C02 and 65CD02 cpus 2025-07-17 19:17:03 +02:00
Bob Andrews
3f3dc3d145 Merge pull request #2803 from kugelfuhr/kugelfuhr/fix-1162
Add a description for --memory-model to the docs
2025-07-16 00:56:36 +02:00
Bob Andrews
89704a6e37 Merge pull request #2802 from kugelfuhr/kugelfuhr/modernize-ld65-diags
Modernize ld65 diagnostics
2025-07-16 00:55:12 +02:00
Kugel Fuhr
f86f602b9e Add a description for --memory-model to the docs. 2025-07-14 16:45:42 +02:00
Kugel Fuhr
4120f35276 Added tests for warnings or errors that now have notifications. 2025-07-14 12:59:52 +02:00
Kugel Fuhr
170ddc6e33 Add a --warnings-as-errors option to cc65 for compatibility reasons. 2025-07-14 11:35:53 +02:00
Kugel Fuhr
c7096ab6d7 Fix an error that was introduced by me in a4a24280f2:
Using a pipe causes a subshell to be generated so the "exit" statements will
just leave the subshell. As a consequence, the sortedxxx.sh scripts produced
output but no error exit code. Which in turn caused an error in #2778 to slip
through undetected.
2025-07-13 17:56:31 +02:00
Kugel Fuhr
2e4c18770b Add a --warnings-as-errors to cl65. 2025-07-13 16:34:36 +02:00
Kugel Fuhr
c2f17b6f6b When initialized data is found in a segment, print the first module where this
data comes from to ease debugging.
2025-07-13 16:34:29 +02:00
Kugel Fuhr
2e3edf9b1b Some reformatting and improved diagnostics. 2025-07-13 16:34:20 +02:00
Kugel Fuhr
3e81cd6ae0 Renames CfgError -> PError, CfgWarning -> PWarning. 2025-07-13 16:33:59 +02:00
Kugel Fuhr
7d963d4490 Change the output format for .assert. Use --no-utf8 for the tests. 2025-07-13 16:33:15 +02:00
Kugel Fuhr
074a3f513e Add the --color and --no-utf8 options to cl65 which will pass it to the tools
that understand it.
2025-07-13 16:33:03 +02:00
Kugel Fuhr
79967ff01b Support colors in diagnostic output. 2025-07-13 16:32:56 +02:00
Kugel Fuhr
96f8ce4cee Move the functions to output config file errors from scanner.c to error.c. 2025-07-13 16:32:47 +02:00
Kugel Fuhr
6f45af3c9e Use console properties. Add the --no-utf8 and --color options. 2025-07-13 16:32:37 +02:00
Kugel Fuhr
da0e3907ec Move the code to parse color strings into the CP_Parse() function and use it. 2025-07-13 16:32:23 +02:00
mrdudz
c13f7dbdad fix range check 2025-07-11 18:44:58 +02:00
Bob Andrews
f7ebd4dfea Merge branch 'master' into seglist 2025-07-10 22:21:57 +02:00
Bob Andrews
ffa72f56f1 codestyle 2025-07-10 21:19:55 +02:00
Bob Andrews
97e4c6b42f some cosmetics 2025-07-10 21:18:12 +02:00
Bob Andrews
61362779a5 Merge branch 'master' into macexpand 2025-07-10 21:05:20 +02:00
Bob Andrews
d8b4013f3c Merge branch 'master' into seglist 2025-07-10 20:48:28 +02:00
Kugel Fuhr
2926a95e71 Use correct type for function used in atexit(). 2025-07-10 17:14:50 +02:00
Kugel Fuhr
72e3956aeb Add missing definitions for Windows. 2025-07-10 17:14:50 +02:00
Kugel Fuhr
26968ffdf2 Fixed a typo :-( 2025-07-10 17:14:50 +02:00
Kugel Fuhr
bb255838a6 Fix include files for Windows (hopefully). 2025-07-10 17:14:50 +02:00
Kugel Fuhr
0c14830da0 Remove tabs. 2025-07-10 17:14:50 +02:00
Kugel Fuhr
abb0adf546 Update visual studio project files with added sources. 2025-07-10 17:14:50 +02:00
Kugel Fuhr
7e97e99bae Do also color quoted text. 2025-07-10 17:14:50 +02:00
Kugel Fuhr
8d7c87f753 Fix problem with UTF-8 output when switching the code page under windows fails. 2025-07-10 17:14:50 +02:00
Kugel Fuhr
c466faf484 Use UTF-8 for diagnostic output if it is available. Added a command line
switch --no-utf8 to disable the use of UTF-8 characters.
2025-07-10 17:14:50 +02:00
Kugel Fuhr
b1eb1bf6ab Colorize diagnostics. 2025-07-10 17:14:50 +02:00
Bob Andrews
4afbd1104d Merge pull request #2777 from kugelfuhr/kugelfuhr/ca65-errors
Improve error handling for ca65
2025-07-10 17:05:32 +02:00
Bob Andrews
4a53a891e8 Merge pull request #2778 from colinleroy/optimise-ldaxi
Optimise ldaxi
2025-07-10 17:03:28 +02:00
Bob Andrews
9971d9fac0 Merge pull request #2776 from colinleroy/optimize-incdecsp-further
Further optimize inc/decsp
2025-07-10 17:02:32 +02:00
mrdudz
18bb697891 fix stderr redirection 2025-07-09 14:20:42 +02:00
Bob Andrews
7c6efded1c Merge pull request #2782 from kugelfuhr/kugelfuhr/use-static-inline
Use "static inline" instead of macros in the source
2025-07-07 23:25:11 +02:00
Kugel Fuhr
9be9003e9a Removed the inline.h module and removed the use of macros instead of "static
inline".
2025-07-07 11:23:12 +02:00
Kugel Fuhr
8dc815f53f Fixed typos in comments. 2025-07-06 21:07:34 +02:00
Colin Leroy-Mira
20a9db757d Optimize multiple incax* and incax*/ldaxi
- Group multiple calls to incax* and decax* into a single one
- Replace incaxN/jsr ldaxi with ldy #N+1/jsr ldaxidx

Fixes #2055
2025-07-06 20:37:01 +02:00
Kugel Fuhr
b7e592699d Fix a copy&paste error (mrduz). 2025-07-06 20:20:32 +02:00
Colin Leroy-Mira
fe86149203 Further optimize inc/decsp
The optimizer can now merge incsp+decsp together, and merge
jsr incsp/decsp + jmp incsp/decsp together. Drop the code
altogether if both instructions cancel each other out.

Fixes #2748
2025-07-06 13:30:33 +02:00
Kugel Fuhr
4a8498cb0a When skipping a macro definintion because of an error, apply the same handling
regarding .endmacro as when the macro is parsed regularily: A .endmacro ends
the macro only if is the first token on a line.
2025-07-06 12:45:16 +02:00
Kugel Fuhr
23086bccff Much improved diagnostics for macros. 2025-07-06 10:41:12 +02:00
Kugel Fuhr
7cd137afb4 Improved diagnostics. 2025-07-06 10:40:25 +02:00
Kugel Fuhr
45a326750c Added a function to output notifications. 2025-07-06 10:39:29 +02:00