@neocompose/cli 0.76.1 → 0.76.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,61 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.76.3
4
+
5
+ ### Patch Changes
6
+
7
+ - 62912f7: Generic constructions whose collection type arguments appear only in code, such as a `Box<List<int>>` built inside a function, now run in functions and specs without an unrelated field that declares the same type. Dictionaries are fixed too.
8
+ - 19ac23d: Completion, go to definition, references, and rename now work on a local assigned from a conditional, such as `var item = ready ? first : second;`.
9
+ - 734baf4: Members of a delegate call's result, such as `factory().Count`, complete and rename again, and a lambda that returns `new(...)` gets constructor argument help.
10
+ - 2bf9270: Delegates can now be called straight from an index, a conditional, a function result, or a force-unwrapped value, such as `callbacks["key"]!()`, `(condition ? first : second)()`, or `Factory.Make()()`. These calls get the same argument, return type, and null checks as other delegate calls.
11
+ - b971d88: An enum default of the wrong type is reported at the expression you wrote instead of failing later. An invalid local definition reports its own error instead of breaking the values that use it. Qualified enum options work in instance defaults, and `neo pull` writes a nested enum value that refers to another stored value as `Reference<…>(id: …)` instead of a plain string.
12
+ - 7643c12: A collection field initialized from a class header parameter, such as `class Box<T>(List<T> value) { public List<T> Value = value; }`, keeps its element type. Unused generic classes now push, and compiler errors keep their file and line.
13
+ - 04a188d: Delegate fields with defaults, such as `public NeoDelegate<int> Value = () => this.Number;`, now run on new and stored instances. An invalid lambda is reported at its line by status and editor validation.
14
+ - dc3ab1d: When a list or dictionary is extracted into a local definition, invalid entries are reported at that definition in status, editor validation, and push or test preparation. Invalid qualified enum keys are reported where they are written, and an invalid option written as `.Name` is reported at that option.
15
+ - 77e4479: Member completion works again after `?.` and `!.`, including on dictionary values such as `items["key"]?.` and on partly typed member names.
16
+ - 1d7b2a3: Large pushes prepare faster.
17
+ - fbab09a: Push, test, and status are faster on projects with many stored instances.
18
+ - 1052547: Static delegate fields, such as `public static NeoDelegate<int> Value = () => Number;`, and lambdas passed to constructors in static fields now run. Invalid lambdas passed to constructors in field values are now reported by status and editor validation, not only when preparing a push or test.
19
+ - 621cb75: A static field can now be initialized by calling another class's static delegate, such as `Helper.Run()`, or by reading a field of a new instance, such as `new Counter().Count`. Status and editor validation now accept a static field built from a generic type that only code names, such as `new Box<List<int>>([1]).Value[0]`, instead of reporting a missing type descriptor.
20
+ - 1ed5f02: Generic constructors accept collection arguments: static fields such as `public static Box<List<int>> Value = new([1, 2]);` now prepare and run with populated, empty, or nested lists and dictionaries.
21
+
22
+ ## 0.76.2
23
+
24
+ ### Patch Changes
25
+
26
+ - 483f1ae: Signature help and completion now find call arguments from real tokens, so commas and parentheses inside comments no longer change the active parameter or the expected type. A lambda body passed as an argument, such as a `test` or `describe` callback, gets its own statement and expression context. Constructors appear in completion inside spec callbacks again, and signature help no longer shows the outer call while you edit the callback body.
27
+ - 9f718d8: Method and constructor completions insert only the name. Typing `(` to accept one now opens a single argument list with the cursor inside it, and completing a name before an existing argument list keeps those arguments instead of adding a second call. `Where`, `First`, `FirstOrDefault`, and `Select` now show the callback the compiler requires in completion, hover, and signature help, and `First` and `FirstOrDefault` show their predicate as optional. `Where` and `Select` results are typed as read-only lists, matching the compiler. A collection callback argument no longer offers values or `null`, since only a lambda compiles there.
28
+ - c064a34: Target-typed `new(...)` in function bodies, such as a typed local, a return, an assignment, an argument, or a list element or dictionary value inside one, now gets signature help, enum completion, hover, and parameter hints from the type its context expects, as field initializers already did. Generic constructions keep their type arguments: `var box = new Box<int>(1);` infers `Box<int>`, `box.Value` and `new Box<int>(1).Value` show `int`, and rename and references reach members accessed through the substituted type.
29
+ - a683e01: Report the original compiler diagnostic when a stored initializer reads a getter whose body fails to compile, instead of failing status with `Expected a numeric literal.` An unresolved name in a scalar, vector, color, Class, enum, sprite, audio, lookup, list, or dictionary initializer, such as `= unknown`, `= Probe.Missing`, or `= Hue.Missing`, is reported by the compiler where it was written, including inside a negation, a vector component, or a multiselect enum element. NeoScript accepts the named `new Vector2(x, y)` spelling wherever target-typed `new(x, y)` constructs a vector, and a set's list literal reads contextual `.Option` elements. `new Color(…)` reports that Color components must be numeric literals instead of calling Color an unknown Class. Retained initializer code compiles only when the code, its owner scope, or the compiler project changes, so validating an unchanged checkout stays as fast as before. Editing a pulled literal row to code now compiles that code, so a typo is reported instead of silently keeping the stored value. Report a stored initializer compile failure, such as an unknown constructor argument, at its authored file, line, and column in status, editor validation, and push preparation, without generated IDs. Editor validation no longer attaches errors without a source file to `Project.neo`; VS Code shows them on the workspace's `neo.json`.
30
+ - bc70516: Status and editor validation now report an instance field default that fails when constructed, such as `public int Value = 10 / 0;`, a default calling a helper that throws, `public Item Value = new Item(unknown);`, or a construction nested in the default such as `public Probe P = new Probe() { Value = 10 / 0 };`. Push, test, and export preparation already rejected these. Every path reports the failure at the same authored file, line, and column: the failing expression in the default, or in the helper it called.
31
+ - a1179b2: Typed generic locals such as `NeoDelegate<int, int> f = (x) => x;` and `Box<int> box = new(1);` now compile as declarations, with lambdas typed from the declared delegate. The editor's immediate diagnostics no longer flash false errors on typed collection locals, target-typed `new(...)`, named arguments, object initializer members, scalar methods such as `Trim()`, `EndsWith(...)`, `ToFloat()`, and `ToDecimal(...)`, collection `Find(...)` (whose lambda parameter is now typed), `is` pattern bindings, or `OnChanged` listener sets, and typed `List<T>` locals support hover, go to definition, rename, and member completion.
32
+
33
+ `AudioClipInfo` now compiles the members the runtime reads and the editor lists, `FileId`, `Name`, and `DurationSeconds`. The previously accepted `url`, `name`, and `length` always failed at runtime with a missing key, so they are now compile errors.
34
+
35
+ - 63b16ef: Formatting source that ends inside an unfinished `"""` string no longer adds a
36
+ newline to the string on every run, so repeated formatting converges. NeoFlow
37
+ prose content and its closing `"""` now follow the opening `"""`: pull and push
38
+ emit them at the opening's indentation, and re-indenting a file moves them with
39
+ it. The prose text doesn't change.
40
+ - d4cae22: Named arguments now drive IntelliSense by name. Signature help highlights the parameter an argument's `name:` label names, even when arguments are reordered or mixed with positional ones, and selects the constructor overload the compiler binds for those names. Contextual enum completions and enum renames follow the named parameter's type. A named argument's colon no longer offers statement and declaration snippets, and named arguments no longer get positional parameter-name inlay hints. Value-source `new(…)` and function-call signature help resolve named arguments the same way, including overloaded constructors. A value source's named argument offers values rather than further argument names, keeps its parameter's type through a conditional, and nested calls' names no longer hide the outer call's argument names. A label that names no parameter highlights none.
41
+ - 811c09c: Renaming a constructor parameter now renames the named arguments that bind it, such as `count:` in `new Item(count: 1)`, in function bodies, field initializers, specs, and base clauses (`: base(count: …)` and `: Item(count: …)`). Renaming a constructor parameter also renames its uses inside that constructor's `: base(...)` clause. Find references and go to definition include those arguments. Labels resolve to the overload the compiler picks, so a same-named parameter on another overload or class is left alone.
42
+ - a921f86: Fix `neo test` failing on a cold cache with "NSFunction argument 1 does not match its declared runtime type" when a moved body passes a method as a delegate (`this.OnChanged`). Reusing compiled IR after a source move no longer adds an empty `action` key to member delegate targets, so cold and cached runs evaluate the same program.
43
+ - 576ad5a: `neo status` and full VS Code validation now compile NeoFlow interpolations, dialogue functions, conditions, and actions the way push does. Errors such as unknown identifiers or missing members appear at their authored location before you push. This includes pulled dialogues broken by a schema edit.
44
+ - c38d744: NeoFlow helpers authored as `=> expr` now compile exactly like their block-bodied equivalents when called from text, conditions, or actions. A failing helper body (block or expression) is reported at its authored position inside the helper, not on a later node, and without generated-code coordinates.
45
+ - 94217bb: `neo push` no longer rewrites source it didn't change. A file that gets no new
46
+ IDs keeps its bytes, so indented dialogue literals and block-bodied methods
47
+ survive unrelated pushes. Assigned `@id`s, including those on new nested list
48
+ rows, dialogue nodes, actions and priority options, are inserted into the
49
+ authored text, so comments, layout, positional constructor arguments and
50
+ target-typed `new()` stay as written. Each new list row gets its ID where it was
51
+ written, in unordered lists too. A new row such as `2 + 3` or `A.B * 2` gets its
52
+ ID with parentheses, `@id("…") (A.B * 2)`, so the ID names the whole row, and
53
+ `neo push --dry-run` accepts it. A row that is already parenthesized keeps its
54
+ single parentheses, and one stored with them before reads as unchanged. A
55
+ declaration whose IDs can't be placed is re-emitted on its own; the rest of its
56
+ file keeps its text.
57
+ - 5c87223: Status, the editor, and push preparation now compile a variant's `initialize:` and `apply:` callbacks and type-check its `overrides:`, including child overrides, the same way. Each failure points at the callback or field in your file, not a generated value ID or the variant declaration. One invalid variant no longer hides diagnostics in the rest of the workspace.
58
+
3
59
  ## 0.76.1
4
60
 
5
61
  ### Patch Changes