Files
marqdo/tests/ext/quantum-gate-matrix-smoke.mq.md
T
cflmyandCursor 687c168014 feat(parse): use nested YAML import: maps instead of one-liner binds
Frontmatter imports are now valid YAML (`import:` / `导入:` with bind→target
entries), removing spaced keys. Add `marqdo migrate imports`, hard-error the
old one-liner form, and migrate lib/ext/examples/tests/docs accordingly.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-10-23 19:33:58 +08:00

600 B

title, description, import
title description import
quantum gate matches_matrix smoke Named H matches an explicit 2x2 nested list.
quantum json
ext/quantum/quantum.mq.md lib/json.mq.md

main

H_matrix = > json.parse text=0.7071067811865475,0.7071067811865475],[0.7071067811865475,-0.7071067811865475 H = > quantum.gate name="H" ok = > H.matches_matrix matrix=H_matrix

  1. ok

print text=match-ok

print text=match-fail

bad = > json.parse text=1,0],[0,1 no = > H.matches_matrix matrix=bad

  1. not no

print text=reject-ok

print text=reject-fail