Commit Graph
100 Commits
Author SHA1 Message Date
sergeych 66b8806b11 Add runnable DB serialization example 2026-04-25 16:23:08 +03:00
sergeych 92e9325f40 Add SQL object expansion serialization support 2026-04-25 16:09:30 +03:00
sergeych 50e34e520e Add DB decode annotations and preserved declaration metadata 2026-04-25 13:36:33 +03:00
sergeych 2abe7e2f96 Add typed canonical JSON encoding 2026-04-25 00:36:18 +03:00
sergeych 2bedaa0969 Add canonical Json format and external format binding 2026-04-25 00:03:00 +03:00
sergeych 9735774efd v1.5.5 release 2026-04-23 15:18:47 +03:00
sergeych 14214e91e1 Fix escaping immutable closure captures 2026-04-22 18:50:49 +03:00
sergeychandClaude Sonnet 4.6 0f5343fa17 Add VPS deployment target and Ansible provisioning for lynglang.com
- deploy_site now defaults to new VPS (94.130.36.94, /var/www/lynglang);
  use --old to deploy to d.lynglang.com as before
- infra/setup_vps.yml: Ansible playbook installs nginx + certbot, obtains
  SSL cert for lynglang.com, fixes Debian buster EOL apt sources
- infra/inventory.ini and infra/templates/nginx_lynglang.conf.j2 included

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-22 12:31:01 +03:00
sergeych d0f51928de fixed wrong error message in val ++/-- 2026-04-22 08:56:02 +03:00
sergeych 0973a6afeb Fix JVM import caching and class/object bytecode dispatch 2026-04-21 23:25:07 +03:00
sergeych 953f237ca3 Optimize primitive list fill capacity and append 2026-04-21 21:37:04 +03:00
sergeych fbb5688696 Drive higher-order lambda inlining from call metadata 2026-04-21 20:51:16 +03:00
sergeych f4ab2ebab4 Extend lambda inlining to getOrPut and implicit it calls 2026-04-21 19:20:25 +03:00
sergeych 0c3242cbd8 Generalize higher-order lambda inlining 2026-04-21 19:12:16 +03:00
sergeych 1d5caaa836 Broaden lambda method inlining with captures 2026-04-21 19:07:05 +03:00
sergeych 3be2892025 Use fast compiled callbacks in dynamic and flow helpers 2026-04-21 18:06:31 +03:00
sergeych c80900c503 Prevent cross-script module slot aliasing 2026-04-21 17:34:00 +03:00
sergeych ee634c8dff Extend generic fast callable entry points 2026-04-21 17:26:53 +03:00
sergeych 6c91b77a85 Use fast lambda calls in scope facade 2026-04-21 16:43:02 +03:00
sergeych 3721ee8332 Fast-path compiled lambda calls with args 2026-04-21 16:04:04 +03:00
sergeych 97990f00ce Cover when-based exact callable fast paths 2026-04-21 14:37:27 +03:00
sergeych 80693e7690 Inline exact lambdas through wrapper expressions 2026-04-21 14:36:18 +03:00
sergeych 029fe874fa Propagate exact callable refs across expressions 2026-04-21 14:33:23 +03:00
sergeych ffa64d691b Use direct calls for constant constructors 2026-04-21 13:30:09 +03:00
sergeych 30c9a5a565 Propagate exact lambda refs across bytecode slots 2026-04-21 13:20:27 +03:00
sergeych db3a780645 Generalize bytecode fast-call dispatch 2026-04-21 13:09:50 +03:00
sergeych fc7d26ee4b Fast-path bytecode statement execution 2026-04-21 11:39:47 +03:00
sergeych a61b5a31be Add non-suspending fast calls for bytecode callables 2026-04-21 11:35:20 +03:00
sergeych 33d170f525 Optimize fast-path bytecode lambda invocation 2026-04-21 11:29:14 +03:00
sergeych f72cdfdf83 Inline simple lambdas in bytecode fast paths 2026-04-21 09:05:18 +03:00
sergeych 10fa4de4fa regression fix 2026-04-20 18:48:28 +03:00
sergeych 4acee56de8 small optimization of List.fill 2026-04-20 14:09:09 +03:00
sergeych 87060c7eb7 +inference bugs
+List.ensureCapacity
optimized List.fill
2026-04-20 13:56:47 +03:00
sergeych 6ba128f7ba fixed some more inference bugs 2026-04-20 12:23:17 +03:00
sergeych a8f73dc8bd added LaunchPool 2026-04-18 23:37:21 +03:00
sergeychandClaude Sonnet 4.6 145c3ae34a Add completeExceptionally, cancelAndJoin, and refine LaunchPool spec
- CompletableDeferred.completeExceptionally(exception): fails the deferred
  with a Lyng exception; the original exception object is preserved as
  errorObject so assertThrows/catch see the correct class (works for both
  built-in ObjException and user-declared class instances)
- LaunchPool: add maxQueueSize parameter (suspends launch when full),
  add cancelAndJoin() for graceful shutdown that waits for running tasks,
  clarify all semantics in the extern declaration comments
- Two tests for completeExceptionally (built-in and user-defined exception)
- Fix parallelism.md channel doc-test to be illustration-only (avoid
  flakiness from coroutine scheduling in the doc-test runner)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-18 03:00:40 +03:00
sergeychandClaude Sonnet 4.6 f9a07f176a Add Channel primitive for coroutine inter-task communication
Exposes Kotlin's Channel<Obj> to Lyng scripts as a first-class type
with rendezvous, buffered, and unlimited capacity modes. Supports
suspending send/receive, non-suspending tryReceive, close/drain
semantics, and isClosedForSend/isClosedForReceive properties.

Also fixes a pre-existing typo in BookTest.kt that blocked JVM test
compilation, and adds Channel reference docs and a parallelism.md section.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-18 02:28:55 +03:00
sergeych 30e56946a0 improved JDBC provider for lyng.io.db 2026-04-18 02:06:29 +03:00
sergeych 49fc700233 Detach materialized SQL rows from transaction lifetime 2026-04-17 20:38:40 +03:00
sergeych 07cb5a519c Add JDBC and websocket/native follow-up changes 2026-04-16 23:35:15 +03:00
sergeych 8f66cd7680 Fix lynglib binding regressions and green test suite 2026-04-16 23:34:45 +03:00
sergeych bb2119b1d1 ignores 2026-04-16 22:12:19 +03:00
sergeych 64273ac60a Add JDBC database provider for JVM 2026-04-16 22:10:36 +03:00
sergeych ee392daa13 another sample 2026-04-16 13:35:12 +03:00
sergeych 0affa92674 better SQL example 2026-04-16 01:08:31 +03:00
sergeych a2e3f80ab6 better sql exaple, some inference bugs fixed 2026-04-16 00:54:00 +03:00
sergeych f8d2533b48 Make SQLite native linker lookup portable 2026-04-15 23:47:38 +03:00
sergeych bb9af2258b Fix SQLite release deployment 2026-04-15 23:35:59 +03:00
sergeych b3be908242 Add Date type and database release docs 2026-04-15 23:20:23 +03:00
sergeych 14dc73db3e Harden SQLite provider release behavior 2026-04-15 23:11:50 +03:00
sergeych f9bbdd56bf Test DB rollback precedence in SQLite 2026-04-15 22:38:11 +03:00
sergeych 04e80c384e Stabilize DB provider registration test 2026-04-15 22:35:19 +03:00
sergeych 6d340824e4 Tighten SQLite transaction failures and tests 2026-04-15 22:20:29 +03:00
sergeych 5f6f6b9ae4 Align SQLite value conversion across JVM and native 2026-04-15 22:03:42 +03:00
sergeych 55ba6113e7 Add Lyng DB contract and SQLite provider skeleton 2026-04-15 20:39:38 +03:00
sergeych b42ceec686 Preserve VM throw sites in stack traces 2026-04-14 01:17:04 +03:00
sergeych fada848907 Add backtick string literals and formatter support 2026-04-13 23:08:18 +03:00
sergeych e925195495 yet another import fix 2026-04-13 22:49:02 +03:00
sergeych 3b6bdda0a4 another import fix 2026-04-13 20:43:11 +03:00
sergeych ab39110834 Add repeated local import regression coverage 2026-04-12 11:11:32 +03:00
sergeych 47eb2d7d61 Fix transitive import re-exports and stabilize captures 2026-04-12 09:16:58 +03:00
sergeych eefa4c8f1a Fix stdlib import aliasing and launch captures 2026-04-11 20:24:44 +03:00
sergeych 6171b0d95f Fix duplicate stdlib import redefinition 2026-04-11 19:24:08 +03:00
sergeych a1ea09440d Optimize native CLI release binary 2026-04-09 22:30:43 +03:00
sergeych 88ce04102a Add CLI atExit shutdown handlers 2026-04-09 22:17:45 +03:00
sergeych 0e73d80707 plugin fix 2026-04-09 19:37:23 +03:00
sergeych 121d860043 Document native networking limits 2026-04-09 19:17:32 +03:00
sergeych 717758149b cleaned up tcpserver.lyng, again ;) 2026-04-09 19:01:26 +03:00
sergeych 73ec8f9be6 cleaned up tcpserver.lyng/2 2026-04-09 18:28:59 +03:00
sergeych 805c54a408 cleaned up tcpserver.lyng 2026-04-09 18:26:25 +03:00
sergeych 9b90fe370b improved tcpserver.lyng sample 2026-04-09 17:11:30 +03:00
sergeych 840cd32574 Fix captured range bounds in launched for-loops 2026-04-09 17:05:00 +03:00
sergeych fbb1683ba3 Fix concurrent TCP CLI scope and add regressions 2026-04-09 11:55:01 +03:00
sergeych c9eb3df93d Add Deferred.joinAll helper 2026-04-09 11:27:32 +03:00
sergeych 402b8bb1b3 Fix native CLI TCP regression path 2026-04-09 11:00:23 +03:00
sergeych aa1b74620e docs for cli fix; KMP compatibility bug fix 2026-04-08 22:54:22 +03:00
sergeych ef95ed4405 package structure/import for CLI 2026-04-08 22:38:34 +03:00
sergeych b6c6ef021a fixed some exception catching problems on wasm target 2026-04-08 22:05:02 +03:00
sergeych c6cfd52b01 fixed site docs behavior on narrow screens 2026-04-08 10:53:21 +03:00
sergeych 12fb4fe0ba + String.replace 2026-04-08 10:45:01 +03:00
sergeych 368ce2ce8c added buffer.base64std 2026-04-08 09:27:52 +03:00
sergeychandClaude Sonnet 4.6 d0d79d2f07 docs: add LegacyDigest module documentation
- New docs/LegacyDigest.md: full reference for lyng.legacy_digest,
  covering the sha1() API, input types (String / Buffer), FIPS compliance
  note, and explicit guidance on appropriate vs. inappropriate use.

- docs/ai_stdlib_reference.md: entry in section 5 so AI agents know
  LegacyDigest.sha1() exists and is intentionally named as legacy-only.

- docs/whats_new.md: release-note section alongside Complex, Decimal,
  and Matrix, with a minimal runnable example and cross-link.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-07 19:53:01 +03:00
sergeychandClaude Sonnet 4.6 69013392d3 Add lyng.legacy_digest module with LegacyDigest.sha1()
Provides a pure Kotlin/KMP SHA-1 implementation with no extra dependencies,
exposed as `LegacyDigest.sha1(data)` in the `lyng.legacy_digest` package.

The naming deliberately signals that SHA-1 is cryptographically broken:
the object name `LegacyDigest` and prominent doc-comment warnings steer
users away from security-sensitive use while still enabling interoperability
with legacy protocols and file formats that require SHA-1.

API:
  import lyng.legacy_digest
  val hex: String = LegacyDigest.sha1("some string")   // UTF-8 input
  val hex: String = LegacyDigest.sha1(someBuffer)       // raw-byte input

Tests cover FIPS 180-4 known-answer vectors (empty, "abc", long message,
quick-brown-fox) at both the Kotlin and Lyng integration levels.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-07 19:51:04 +03:00
sergeychandClaude Sonnet 4.6 f145a90845 Fix method slot ID collision between instance and static methods
When createField() was called with a pre-assigned methodId, the ID was
used but methodIdMap was not updated and nextMethodId was not advanced.
This caused assignMethodId() for static methods to reuse slot IDs
already occupied by instance methods.

In complex.lyng, fromInt/imaginary got IDs 12/14 (same as plus/mul),
causing binary operator dispatch via CALL_MEMBER_SLOT to call the wrong
function (e.g. a*b would invoke imaginary instead of mul).

Fix: after computing effectiveMethodId in createField, always register
it in methodIdMap and advance nextMethodId past it so subsequent
auto-assignments start from a clean range.

Also pre-assigns method IDs for non-static fun/fn declarations during
class body pre-scan so forward references resolve correctly in class
bodies, and adds ComplexModuleTest coverage for operator slot dispatch.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-07 19:41:18 +03:00
sergeych 2f145a0ea7 Fix nullable let member inference 2026-04-07 09:33:40 +03:00
sergeych 15617f6998 more docs 2026-04-07 01:01:26 +03:00
sergeych 583067780f Support object extension indexers 2026-04-07 00:49:51 +03:00
sergeych 8386337c42 missing docs on object extension 2026-04-07 00:05:34 +03:00
sergeych 83099148bd index return value inference fixed 2026-04-06 20:03:55 +03:00
sergeych 1fca2b112f Fix parsing of generic extension functions 2026-04-06 19:29:06 +03:00
sergeych 35628c8453 Support extensions on singleton objects 2026-04-06 19:24:28 +03:00
sergeych 671583638b v1.5.5-SNAPSHOT started. compile if support 2026-04-06 11:09:14 +03:00
sergeych 214f1aec9e v1.5.4 release 2026-04-05 06:34:30 +03:00
sergeych 657c0c5d18 optimize VM: removed cmd.isFast 2026-04-05 06:12:49 +03:00
sergeych 90718c3c17 optimize VM 2026-04-04 10:35:08 +03:00
sergeych d8454a11fc optimize arithmetics 2026-04-04 04:01:43 +03:00
sergeych 161f3f74e2 fixed disabled concurrency in CLI 2026-04-03 23:42:43 +03:00
sergeych 1cead7822a Prepare 1.5.4 release defaults and metadata 2026-04-03 23:28:09 +03:00
sergeych 064b927b1a Stabilize pi benchmark optimizations for release 2026-04-03 23:16:08 +03:00
sergeych a7ab0d3905 added static List.fill(size) { ... } 2026-04-03 21:15:41 +03:00