Wykres commitów

16 Commity (84fa3312cfa7d2237d4b56952f2cd6e3591210c4)

Autor SHA1 Wiadomość Data
stijn 84fa3312cf all: Format code to add space after C++-style comment start.
Note: the uncrustify configuration is explicitly set to 'add' instead of
'force' in order not to alter the comments which use extra spaces after //
as a means of indenting text for clarity.
2020-04-23 11:24:25 +10:00
Damien George 7bbde67cb2 lib/utils/printf: Exclude __GI_vsnprintf alias for gcc 9 and above.
See issue #4457.
2019-02-06 01:12:51 +11:00
Damien George da2d2b6d88 py/mpconfig.h: Introduce MICROPY_DEBUG_PRINTER for debugging output.
This patch in effect renames MICROPY_DEBUG_PRINTER_DEST to
MICROPY_DEBUG_PRINTER, moving its default definition from
lib/utils/printf.c to py/mpconfig.h to make it official and documented, and
makes this macro a pointer rather than the actual mp_print_t struct.  This
is done to get consistency with MICROPY_ERROR_PRINTER, and provide this
macro for use outside just lib/utils/printf.c.

Ports are updated to use the new macro name.
2018-08-02 14:04:44 +10:00
stijn 8ad30fa433 lib/utils/printf: Make DEBUG_printf implementation more accessible.
The definition of DEBUG_printf doesn't depend on
MICROPY_USE_INTERNAL_PRINTF so move it out of that preprocessor
block and compile it conditionally just depending on the
MICROPY_DEBUG_PRINTERS macro. This allows a port to use DEBUG_printf
while providing it's own printf definition.
2018-07-05 19:44:18 +10:00
Alexander Steffen 55f33240f3 all: Use the name MicroPython consistently in comments
There were several different spellings of MicroPython present in comments,
when there should be only one.
2017-07-31 18:35:40 +10:00
Delio Brignoli e2ac8bb3f1 py: Add MICROPY_USE_INTERNAL_PRINTF option, defaults to enabled.
This new config option allows to control whether MicroPython uses its own
internal printf or not (if not, an external one should be linked in).
Accompanying this new option is the inclusion of lib/utils/printf.c in the
core list of source files, so that ports no longer need to include it
themselves.
2016-09-05 12:18:53 +10:00
Paul Sokolovsky 47442d9f52 lib/utils/printf: Rework overriding printer of DEBUG_printf().
By default it uses mp_plat_print, but a port may override it to another
value with MICROPY_DEBUG_PRINTER_DEST.
2016-04-13 11:53:12 +03:00
Paul Sokolovsky f2ed736b29 lib/utils/printf: Add vsnprintf alias for Clang.
Was reported to break MacOSX build.
2015-12-12 20:19:42 +02:00
Paul Sokolovsky 1f0aaece3a lib/utils/printf: Apply workaround for static linking with uclibc.
uclibc objects call __GI_vsnprintf().
2015-12-10 14:42:01 +02:00
Damien George 4e7107a572 py: Change mp_print_strn_t func type to use size_t for the str length. 2015-11-29 14:25:04 +00:00
Paul Sokolovsky 4892e4c5fc lib/utils/printf: Use more conservative check for MICROPY_DEBUG_STDERR. 2015-11-23 22:38:48 +02:00
Paul Sokolovsky 1818da2ef3 lib/utils/printf: Fix issue with putchar define for some ports. 2015-11-22 02:46:32 +02:00
Paul Sokolovsky 8ee43e24f3 lib/utils/printf: Add extra prototypes. 2015-11-22 00:59:24 +02:00
Paul Sokolovsky c3280d83e7 unix: Use printf() implementation in terms of mp_printf().
In other words, unix port now uses overriden printf(), instead of using
libc's. This should remove almost all dependency on libc stdio (which
is bloated).
2015-11-22 00:44:41 +02:00
Paul Sokolovsky 295ea12411 py/emitglue: Host definition of mp_verbose_flag.
This may not seem like the ideal place, but is actually the only place
in py/ where it gets referenced, so is just right.
2015-11-21 16:54:15 +02:00
Paul Sokolovsky 73ff0687f2 lib/utils/printf: Move from stmhal/ .
This file contains various MicroPython-specific helper functions, so isn't
good fit for lib/libc/.
2015-11-10 18:58:58 +02:00