1
0
Fork 0
forked from fun/fun

Fixed bug with wrong line numbers in error messages. Fixed permissions on examples. (0.39.14)

This commit is contained in:
Johannes Findeisen 2026-03-30 19:10:29 +02:00
commit 53ccdbda10
26 changed files with 274 additions and 116 deletions

0
examples/arrays/arrays.fun Normal file → Executable file
View file

0
examples/arrays/arrays_advanced.fun Normal file → Executable file
View file

0
examples/arrays/arrays_iter.fun Normal file → Executable file
View file

0
examples/basics/boolean_decl.fun Normal file → Executable file
View file

0
examples/basics/booleans.fun Normal file → Executable file
View file

0
examples/basics/builtins_conversions.fun Normal file → Executable file
View file

0
examples/cli/cli_parse_example.fun Normal file → Executable file
View file

0
examples/crypto/libressl_md5.fun Normal file → Executable file
View file

0
examples/crypto/libressl_ripemd160.fun Normal file → Executable file
View file

0
examples/crypto/libressl_sha256.fun Normal file → Executable file
View file

0
examples/crypto/libressl_sha512.fun Normal file → Executable file
View file

View file

@ -0,0 +1,34 @@
#!/usr/bin/env fun
/*
* This file is part of the Fun programming language.
* https://fun-lang.xyz/
*
* Copyright 2026 Johannes Findeisen <you@hanez.org>
* Licensed under the terms of the Apache-2.0 license.
* https://opensource.org/license/apache-2-0
*
* Added: 2026-03-30
*/
/*
Test: error location in included files shows correct file:line
How to run:
- From repo root: ./build_debug/fun examples/error/include_line_mapping_test.fun
Expected: Runtime error message suffix contains the included file path
(lib/test/include_divzero.fun) and the exact line number of
the failing operation inside that file (see lib file below).
*/
// Use angle-bracket include so resolution tries FUN_LIB_DIR, DEFAULT_LIB_DIR,
// and finally the project-local lib/ directory. This makes the example work
// from the repository without extra setup.
#include <test/include_divzero.fun>
fun main()
// Trigger the division by zero inside the included file
boom()
main()

0
examples/extra/notcurses_menu.fun Normal file → Executable file
View file

0
examples/extra/notcurses_progress.fun Normal file → Executable file
View file

11
examples/io/await_http_client.fun Normal file → Executable file
View file

@ -1,5 +1,16 @@
#!/usr/bin/env fun
/*
* This file is part of the Fun programming language.
* https://fun-lang.xyz/
*
* Copyright 2026 Johannes Findeisen <you@hanez.org>
* Licensed under the terms of the Apache-2.0 license.
* https://opensource.org/license/apache-2-0
*
* Added: 2026-03-29
*/
/*
* Async-style HTTP GET using lib/async/scheduler.fun helpers
*

0
examples/io/file_io.fun Normal file → Executable file
View file

0
examples/snippets/include_namespace.fun Normal file → Executable file
View file

0
examples/snippets/maps_iterate.fun Normal file → Executable file
View file

0
examples/strings/base64_demo.fun Normal file → Executable file
View file