Major changes since last commit: - FiveSql2 SQL:1999 engine (10,458 LOC) — 43/43 ALL PASS - 21 compiler/runtime bugs fixed (short-circuit AND/OR, FOR LOOP, etc.) - @byref pass-by-reference via RefCell pattern - Mutable closure capture (EnsureLocalRef + RefCell sharing) - RTL: 400 → 479 functions (+79: file, string, datetime, hash, UTF-8) - DateTime/Timestamp fully working (hb_DateTime, hb_Hour/Min/Sec, display) - Reserved word guard (39 keywords blocked from function calls) - AEval arg order fix (element before index) - Closure capture redecl fix (unique _cap_ names per block) - Hash/string indexing in ArrayPush/ArrayPop - Harbour compat test suite: 51/51 - 4 docs: Porting Report, Implementation Plan, Optimization Plan, Commercialization Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
26 lines
466 B
Plaintext
26 lines
466 B
Plaintext
#include "FiveSqlDef.ch"
|
|
|
|
FUNCTION Main()
|
|
LOCAL n
|
|
? "Test Used()"
|
|
? "Used:", Used()
|
|
|
|
dbCreate("used_test", { {"ID","N",4,0} })
|
|
USE "used_test" NEW
|
|
? "After USE - Used:", Used()
|
|
? "Alias:", Alias()
|
|
n := Select()
|
|
? "Select():", n
|
|
|
|
// Test (n)->(expr) syntax
|
|
BEGIN SEQUENCE
|
|
? "(n)->(Used()):", (n)->(Used())
|
|
RECOVER
|
|
? "Workarea expr FAILED"
|
|
END SEQUENCE
|
|
|
|
CLOSE ALL
|
|
FErase("used_test.dbf")
|
|
? "DONE"
|
|
RETURN NIL
|