Keywords
This commit is contained in:
@@ -82,12 +82,12 @@ type
|
||||
class function FromRecordSeries(const AValue: IRecordSeries): TDataValue; static; inline;
|
||||
class function FromRecord(const [ref] AValue: TScalarRecord): TDataValue; static; inline;
|
||||
class function FromSeries(const AValue: ISeries): TDataValue; static; inline;
|
||||
class function FromKeyword(const AValue: IKeyword): TDataValue; static; inline; // Added
|
||||
class function FromKeyword(const AValue: IKeyword): TDataValue; static; inline;
|
||||
|
||||
function AsScalar: TScalar; inline;
|
||||
function AsMethod: TFunc; inline;
|
||||
function AsText: String; inline;
|
||||
function AsKeyword: IKeyword; inline; // Added
|
||||
function AsKeyword: IKeyword; inline;
|
||||
function AsRecordSeries: IRecordSeries; inline;
|
||||
function AsRecord: TScalarRecord; inline;
|
||||
function AsSeries: ISeries; inline;
|
||||
@@ -264,7 +264,7 @@ begin
|
||||
TInterlocked.CompareExchange(FScalar.Value.AsInt64, NewValue.AsScalar.Value.AsInt64, Expected.AsScalar.Value.AsInt64)
|
||||
= Expected.AsScalar.Value.AsInt64;
|
||||
|
||||
vkText, vkKeyword, vkSeries, vkRecordSeries, vkRecord, vkManagedObject, vkMethod, vkInterface, vkGeneric: // Added vkKeyword
|
||||
vkText, vkKeyword, vkSeries, vkRecordSeries, vkRecord, vkManagedObject, vkMethod, vkInterface, vkGeneric:
|
||||
Result := IntfCompareExchange(FInterface, NewValue.FInterface, Expected.FInterface) = Expected.FInterface;
|
||||
end;
|
||||
end;
|
||||
@@ -369,7 +369,7 @@ begin
|
||||
end;
|
||||
vkPointer: Result := TInterlocked.Exchange(FScalar.Value.AsInt64, NewValue.AsScalar.Value.AsInt64);
|
||||
|
||||
vkText, vkKeyword, vkSeries, vkRecordSeries, vkRecord, vkManagedObject, vkMethod, vkInterface, vkGeneric: // Added vkKeyword
|
||||
vkText, vkKeyword, vkSeries, vkRecordSeries, vkRecord, vkManagedObject, vkMethod, vkInterface, vkGeneric:
|
||||
begin
|
||||
Result.FKind := FKind;
|
||||
Result.FInterface := IntfExchange(FInterface, NewValue.FInterface);
|
||||
@@ -386,7 +386,7 @@ begin
|
||||
case FKind of
|
||||
vkScalar: Result := FScalar.ToString;
|
||||
vkText: Result := '"' + AsText + '"';
|
||||
vkKeyword: Result := ':' + AsKeyword.Name; // Added
|
||||
vkKeyword: Result := ':' + AsKeyword.Name;
|
||||
vkSeries:
|
||||
begin
|
||||
var series := AsSeries;
|
||||
@@ -404,7 +404,7 @@ begin
|
||||
begin
|
||||
if not first then
|
||||
sb.Append(',');
|
||||
sb.Append(field.Name);
|
||||
sb.Append(field.Key.Name);
|
||||
first := False;
|
||||
end;
|
||||
sb.Append('}');
|
||||
@@ -425,7 +425,7 @@ begin
|
||||
begin
|
||||
if not first then
|
||||
sb.Append(',');
|
||||
sb.Append(field.Name);
|
||||
sb.Append(field.Key.Name);
|
||||
first := False;
|
||||
end;
|
||||
sb.Append('}');
|
||||
@@ -490,7 +490,7 @@ begin
|
||||
vkVoid: Result := 'Void';
|
||||
vkScalar: Result := 'Scalar';
|
||||
vkText: Result := 'Text';
|
||||
vkKeyword: Result := 'Keyword'; // Added
|
||||
vkKeyword: Result := 'Keyword';
|
||||
vkSeries: Result := 'Series';
|
||||
vkRecordSeries: Result := 'RecordSeries';
|
||||
vkRecord: Result := 'Record';
|
||||
|
||||
Reference in New Issue
Block a user