[pull] master from GaijinEntertainment:master#1032
Merged
Conversation
PR #2849 added aliasCacheValid / aliasCacheHasAlias bits to the TypeDecl::flags union for the lazy findAlias subtree cache. They are runtime scratch state set on first findAlias call, not part of the type's semantic identity. They were leaking into getLookupHash, getSemanticHash, and getOwnSemanticHash via hashmix(flags) / hb.update(flags). Within a single compile this is deterministic (same input -> same cache lifecycle -> same bit state). Across two semantically equivalent TypeDecls whose findAlias-call lifecycles differ (one cached, one not), the hashes diverge -- risky for type interning and AOT semantic hashing across module boundaries. Add flagsWithoutAliasCache(td) -- save the two bits via const_cast, clear them, read flags, restore. Use it at the 3 hash sites. No ABI change. dastest 9341 pass. AOT test_aot 8685 pass. JIT smoke clean. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…g, live_load_string PR1 of the widget-infra/live-vars JSON pivot. Pure API addition, no callers yet — PR2 (dasImgui WidgetMeta) and PR3 (LiveVarsPassMacro) land on top of these. sprint_json_at / sscan_json_at take (addr, TypeInfo&) explicitly, mirroring builtin_print_data's addr+TypeInfo entry point. Unlike sprint_json / sscan_json (which take any and route through SimNode_CallBase::types[]), these are usable from sites that only have a raw void? + a typeinfo pointer from typeinfo rtti_typeinfo(value) — e.g. the dasImgui widget dispatcher. Wraps the existing debug_json_value(void*, TypeInfo*, bool) and debug_json_scan(Context&, char*, TypeInfo*, ...) — same underlying impl as sprint_json / sscan_json, just exposed without the typer-baked SimNode call. live_store_string / live_load_string are siblings of live_store_bytes / live_load_bytes for the JSON-text rail. Separate unordered_map<string,string> store so runtime-debugger output of JSON text stays readable instead of being squinted at through a bytes view. Existing bytes API kept untouched. Tests: - tests/json/test_sprint_json_at.das (12 cases, including round-trip against sprint_json for int/uint/int64/bool/string/struct/array/table and human-readable formatting) - tests/json/test_sscan_json_at.das (9 cases: per-primitive parse, struct/array/table, sprint+sscan round-trip) - tests/live_host/test_store_string.das (8 cases: round-trip, overwrite, JSON-content, separate stores) Verified: tests/json 287/287, tests/live_host 83/83 in both interpreter and AOT. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Two fixes from CI + Copilot review:
1. Copilot review (r3294953321): sprint_json_at was registered with
SideEffects::none. The function reads memory through `addr`, so a
`none` tag lets the optimizer treat it as a pure function of the
pointer value — CSE/hoist across mutations of *addr would produce
stale JSON in hot widget-serializer paths. Bump to
SideEffects::modifyExternal, matching sprint_json's registration
in module_builtin_runtime.cpp:2064. The flag is intentionally
pessimistic ("modify" is a superset of "access") since daslang
doesn't surface read-only-through-pointer as a separate tag; the
read-only semantics are correct in code but invisible to the typer.
sscan_json_at already had modifyArgumentAndExternal.
2. Doc build CI failure: the das2rst generator created `// stub`
placeholder files for the two new builtins and the
`Check for // stub in handmade docs` step failed. Provide proper
one-line descriptions for both, matching the sprint_data
precedent.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The previous fixup r1 used `:ref:\`sprint_json <function-builtin-sprint_json>\``, but the actual generated label is `function-builtin_sprint_json_any_bool` (underscored, signature-suffixed). Sphinx reported `undefined label` and the latex build failed. Drop the `:ref:` link entirely — the description is self-contained and doesn't need a cross-ref. Less fragile to the generated-label naming convention. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…sh-skip-aliascache-bits infer: exclude aliasCache scratch bits from TypeDecl hash
…-at-builtins rtti / live_host: sprint_json_at, sscan_json_at, live_store_string (PR1)
…tespace
Logo + slogan
- New daslang glyph SVG (single path, currentColor-tinted) + yellow-on-black
favicon SVG + .ico fallback in site/files/. Old amber-gradient ">" tile
favicon dropped.
- Favicon <link> chain updated on all 6 HTML pages (index, daspkg, downloads,
playground/index, playground/placeholder, blog/template).
- Nav .forge-mark glyph: was a ">" character on amber-gradient tile, now
inline 22px amber daslang SVG. CSS is a thin SVG host with currentColor
flow; applied across all 9 mark instances (nav + footer on each page).
- Hero kicker (a "high-performance programming language" eyebrow) replaced
with the spec lockup: 64px amber glyph + uppercase amber eyebrow on the
right. Mobile collapse: 44px glyph, 11px eyebrow.
- Hero H1: "Not a script. / A language." -> "High-performance code. / that
stands alone." (line 2 amber italic). <title> matches.
Playground output panel
- web/examples/ui/src/main.js: add flushStdioBuffers() that synthesizes a
newline via TTY put_char on FS.streams[1]/[2] when their tty.output line-
buffer is non-empty. Wrapped Module.callMain in a callMainAndFlush() with
finally{} so all three call sites (interpreter run, dastest, single-buffer
fallback) flush at end of run.
Root cause: a trailing print() with no trailing newline leaves bytes
pending in Emscripten's stdout TTY buffer. The next run's first write
appends to that buffer and flushes the concatenation as the new run's
first line - the trailing print appears to "vanish" then resurface fused
with the next run.
- web/examples/ui/src/main.css: add `white-space: pre-wrap` to
.output_line_text so leading whitespace in compiler log dumps (indented
AST output) is preserved.
…nd-playground-fixes site: refresh logo/slogan/favicon; playground: fix stdout flush + whitespace
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )