fix(bif): set IFACE_VERSION to 2 for the v0.12.0 release (was 1 in public v0.11.x)
The .bif format was bumped 1->2->3 internally across this development cycle, but
the last PUBLIC commit (d56bdbf, release v0.11.x) shipped IFACE_VERSION = 1 with
COMPILER_ID +bif1. None of the intermediate v2/v3 layouts ever reached a public
reader, so the cumulative format change since v1 is a SINGLE public step: collapse
it to v2.
- IFACE_VERSION 3 -> 2; comment now lists all the META/record additions made this
cycle under v2 (ImplUsedUnits + HasInitialization, block local var decls,
Exit value, parameter defaults, free-routine ResolvedQbeName, generic-class
template properties, TRoutineSig vtable facts).
- COMPILER_ID stays blaise-0.12.0-SNAPSHOT+bif2 (now matches IFACE_VERSION).
- Magic-string test updated to expect 'BLAISE-IFACE 2'.
v1 .bif written by v0.11.x are rejected and recompiled from source, as intended.
This commit is contained in:
parent
88a11034b9
commit
4547a9e174
|
|
@ -53,11 +53,21 @@ uses
|
|||
|
||||
const
|
||||
IFACE_MAGIC = 'BLAISE-IFACE';
|
||||
IFACE_VERSION = 3; { v2: META block carries ImplUsedUnits + HasInitialization
|
||||
v3: EncodeBlock carries local var declarations so generic
|
||||
template method bodies round-trip with their locals
|
||||
(e.g. 'var Ptr: ^T'); without this an instantiation
|
||||
from a cached .bif fails with 'Undeclared variable'. }
|
||||
IFACE_VERSION = 2; { v1: shipped through release v0.11.x (last public commit
|
||||
d56bdbf).
|
||||
v2 (release v0.12.0): a batch of META/record additions
|
||||
made this cycle, all gated by this single bump since
|
||||
v1 never reached a reader that lacked them:
|
||||
- META block carries ImplUsedUnits + HasInitialization
|
||||
- EncodeBlock carries local var declarations so generic
|
||||
template method bodies round-trip with their locals
|
||||
(e.g. 'var Ptr: ^T')
|
||||
- Exit(value) carries its return value
|
||||
- parameter default values are serialised
|
||||
- free-routine ResolvedQbeName, generic-class template
|
||||
properties, and TRoutineSig vtable facts
|
||||
(VTableSlot/IsVirtual/IsOverride) round-trip.
|
||||
Old (v1) .bif are rejected and recompiled from source. }
|
||||
|
||||
type
|
||||
EIfaceFormatError = class(Exception);
|
||||
|
|
|
|||
|
|
@ -2683,7 +2683,7 @@ begin
|
|||
Buf := WriteUnitInterface(Iface);
|
||||
{ Blaise Pos is 0-based; match-at-start returns 0. }
|
||||
AssertTrue('starts with magic',
|
||||
Pos('BLAISE-IFACE 3', Buf) = 0);
|
||||
Pos('BLAISE-IFACE 2', Buf) = 0);
|
||||
finally
|
||||
Iface.Free();
|
||||
end;
|
||||
|
|
|
|||
Loading…
Reference in a new issue