jerryscript-project / jerryscript

Ultra-lightweight JavaScript engine for the Internet of Things.
https://jerryscript.net
Apache License 2.0
6.91k stars 669 forks source link

Fixes nuttx target warning #4984

Open lygstate opened 2 years ago

lygstate commented 2 years ago
jerry-main.c: In function 'str_to_uint':
jerry-main.c:89:12: warning: assignment discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
   89 |     *out_p = num_str_p;
make[4]: Leaving directory '/home/runner/work/jerryscript/jerryscript/targets/os/nuttx'
make[3]: Leaving directory '/home/runner/work/jerryscript/apps'

JerryScript-DCO-1.0-Signed-off-by: Yonggang Luo luoyonggang@gmail.com

rtakacs commented 2 years ago

Good catch! I think, it's better to remove that parameter since str_to_num is used only once at jerry-main.c:179 with NULL argument for out_p.

rtakacs commented 2 years ago

LGTM (informal)